DuaneB:
Anyone else have a little smile at this today -Nick, thanks for replying.
foo = s
;
won't compile.
[/quote]
[/quote]
While it obviously doesn't mean what the user wants it to mean, one of the little known areas of C and C++ is that you can do:
int foo(int n){ return "0123456789abcdef"[n & 0xf]; }
and
int bar(int n){ return (n & 0xf)["0123456789abcdef"]; }