Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.

ID: 20255, More accessebility to set elements

by Daniel Baulig Email: Anonymous

It should be possible to access each element in a set without needing to check each possible element for it's occurance
Download Details
FTP  download also available 0 bytes
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For Delphi, Version 7.0  to 7.0 7 downloads
Copyright: No significant restrictions

Size: 0 bytes
Updated on Sat, 23 Aug 2003 09:37:35 GMT
Originally uploaded on Sun, 29 Jun 2003 13:31:40 GMT
if you want to access each element in a set, you'll need to do somethin like that:

SetOfInts: TIntSet;
Value: Integer;
for Value := Low(Integer) to Hight(Integer) do
if Value in SetOfInts then
//DoSomething with Value

thats neither nice nore is it very performant
something like the following would look much nicer and would give a lot more power to sets

SetOfInts: TIntSet;
Value: Integer;
foreach Value in SetOfInts do
// Do Something with Value
PS: I just found the construct as in php would suite the needs more: foreach SetOfInts as Value do
//Do something with Value

   Latest Comments  View All Add New

Move mouse over comment to see the full text

Could not retrieve comments. Please try again later.

Server Response from: ETNACDC04