C
chits
Hello Friends ,
Please help me out in this problem..
I need to use scietific notation (1.2e-2 like) for any given number..
i used cout.flags(ios_base::scientific)
now I see the output in 'e' format which is OK...
now I want to capture this output in a string..so basically I want to
capture cout output in a char * buffer ...
How should I do that...
One long way is to write the number in file and then read the file in
a char buffer..
Is their any smarter way for this ?
Please help me out in this problem..
I need to use scietific notation (1.2e-2 like) for any given number..
i used cout.flags(ios_base::scientific)
now I see the output in 'e' format which is OK...
now I want to capture this output in a string..so basically I want to
capture cout output in a char * buffer ...
How should I do that...
One long way is to write the number in file and then read the file in
a char buffer..
Is their any smarter way for this ?