AnsweredAssumed Answered

printf  format %e does not work.

Question asked by Daniel Chai on Sep 8, 2013
Latest reply on Sep 9, 2013 by Daniel Chai

Hi All,

 

I have a float number data = 25.99978

and I want to using sprintf to format it to %e.

 

sprintf(pointer, "%15.8e", data);

but pointer always 2.5e+01.

 

How should I do so it can format the width to 15 and precision to 8.

 

Thank you.

 

-Daniel

Outcomes