From: JonY <10...@gm...> - 2008-12-13 02:30:12
|
On 12/13/2008 10:05, Sisyphus wrote: > Hi, > > With what, in the below program, should I replace "%Lf\n", in order that > the desired value (0.032258) is printed out. > Currently, I'm getting -0.000000. > ----------------------- > #include<stdio.h> > > int main (void) > { > long double d = 1. / 31.; > printf ("%Lf\n", d); > return 0; > } > > ---------------------- > > Google will only tell me that "%Lf" is broken on MinGW (as of a few years > ago), and the wiki has been removed. > > Cheers, > Rob > > Hi, Try adding "-D__USE_MINGW_ANSI_STDIO" to gcc when compiling it. |