printf does not print long long ints properly
Rolf Campbell
Endlisnis@mailc.net
Sat Jan 24 04:27:00 GMT 2004
"ll" is the long long prefix.
Daniel JeliĂąski wrote:
> when I compile the following program:
>
> #include <stdio.h>
> main()
> {
> long long i;
> i=1000000;
> i*=1000000;
> printf("%Ld",i);
> return 0;
> }
>
> I get the following:
> -727379968
> instead of the expected 1000000000000
>
> I am using gcc 3.3.1
> the same code works nicely on linux machine with gcc 3.3.1
>
> is any other information necessary?
>
> dj
>
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
More information about the Cygwin
mailing list