bail3yz
asked on
How can I format a double to have only 2 decimal places? C++
I need to format a double so it only has 2 decimal places.. the length of the double is always different.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
sprintf(s, "%.2f", 322.33333);
Works.. needed the %..
Thanks!
Works.. needed the %..
Thanks!
sorry, not quite woken up yet.
ASKER