cut off zeroes from double datatype

hey I just wanted to know a way to cut off any remaining zeroes from a double data type. I' trying to calculate cost and output it but it keeps adding a bunch of zeroes on the end. I know there must be a way to
Check out setprecision() in <iomanip>

http://www.cplusplus.com/reference/iomanip/setprecision/
Topic archived. No new replies allowed.