Y
Yakov
What would be the nicest way to write the loop for all values of
unsigned short (0..0xffff), usnig 'unsigned short port;' as an index ?
For comparison, there is just one way to write the for(k=0; k<1000; k+
+) loop, but there seems to be several subtle ways to enumerate all
0..0xffff values using ushort.
And no, for(port=0; port <PORT_MAX; port++) {} is not one of them.
Yakov
unsigned short (0..0xffff), usnig 'unsigned short port;' as an index ?
For comparison, there is just one way to write the for(k=0; k<1000; k+
+) loop, but there seems to be several subtle ways to enumerate all
0..0xffff values using ushort.
And no, for(port=0; port <PORT_MAX; port++) {} is not one of them.
Yakov