I want to print numbers in the following allignmrnt:
455345
989
456.56
Notice that the decimal point will always be in the same spot no matter how large or small is the number
currently my program prints: 455345
989
456.56
help please!!!!
I want to print numbers in the following allignmrnt:
455345
989
456.56
Notice that the decimal point will always be in the same spot no matter how large or small is the number
currently my program prints: 455345
989
456.56
help please!!!!
Do you want to output the decimal points for all values? For example:
1234.45
3333.00
If yes, use std::fixed and std::showpoint.
Otherwise, another solution is an ostringstream. You will have to come up with an algorithm to analyze all situation and add spaces at the end of each string variabl.e
Kuphryn
Look at previous posts (threads) the answer or something similar has allready been answered.
Mr. C: Author and Instructor