Friday, July 16, 2010

printf("%d");

Depends on the compiler, and the result is unpredictable:
  1. G++ doesn't complain and compiles, not even a warning, the output is a random number
  2. VC++ compiler complains with C4313, the output is zero
  3. Intel C++ complains with warning #267 the result is a random number

No comments:

Post a Comment