More fun with C. The following code _correctly_ prints "Not one". void isOne(int i) { if (i == 1) printf("One\n"); else printf("Not one\n"); } int main() { struct { int a:1; }s; s.a = 1; isOne(s.a); return 0; }
-
-
I didn't think that far ahead when I thought about the other signed reprs (1 => -0)- gotta make sure my code compiles for Unisys, after all- but you're right :)
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.