That's just a matter of output formatting. Read up on the setprecision() manipulator if using cout, or the detailed format string documentation if using printf().