using the library iomanip

Hi guys,
i have a question regarding the use of iomanip library.
say i have a const double num5 = 34.890;

but i wanna display the following:
num5 = $**34.890

how can i write my cout code using iomanip library commands??

appreciate your help alot!
I think I don't understand what you want.
std::cout << "$**" << num5;
Are you looking to set the precision of the output maybe?
Here is the code :
1
2
cout.fill('*');
cout << "$" << setw(8) << cout.fill() << setprecision(3) << num5 ;

I think it's true.
setw() and setprecision() functions are in iomanip.h
i am sorry if its unclear...

i meant:

const double num5 = 34.890;

i have the above double fixed value.

and my job now is to output

num5 = $**34.890 exactly as it is, using commands from the library iomanip.
Topic archived. No new replies allowed.