cancel
Showing results for 
Search instead for 
Did you mean: 

%f in sprintf()

shinnlin
Associate II
Posted on January 31, 2005 at 09:23

%f in sprintf()

1 REPLY 1
shinnlin
Associate II
Posted on January 28, 2005 at 00:18

There's a problem in using %f in sprintf() under RVDK.

When print a floating point value to a string using sprintf(),

the dot will be lost in the result string.

Seems there's bugs in RVDK C Library ?!

e.g.

float a = 1.2345;

char str[32];

sprintf( str, ''%f'', a);

====> str[] will be ''1 2345'', not ''1.2345''

====> the dot is missing