不是说long long类型在微软操作系统下必须用%I64d来输出吗?为什么在VC2010下也可以用%lld来输出? long long x=9223372036854775807; printf("%lld\n",x); 成功输出了:9223372036854775807 而DEV和CODE:BLOCKS则必须使用%I64d,用%lld输出的是long型的最大值,请问这是怎么回事?
Size Prefixes for printf and wprintf Format-Type Specifiers
To specify Use prefix With type specifier
long int
l (lowercase L)
d, i, o, x, ……
[/Quote]
查得是vc2005的,之后的版本应该都是相等的了