The Microsoft Input/Output Stream Classes (iostream.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
setprecision
ios                                         Up Contents Index Back
──The Microsoft iostream Classes────────────────────────────────────────────
 
  SMANIP( int ) setprecision( int np );
 
  #include <iomanip.h>
 
  Parameter   Description
 
  <np>        An integer that indicates the number of significant digits
              or significant decimal digits to be used for floating-point
              display.
 
  Remarks
 
  This parameterized manipulator sets the stream's internal floating-point
  precision variable to <np>. The default precision is six digits. If the
  display format is scientific or fixed, then the precision indicates the
  number of digits after the decimal point. If the format is automatic
  (neither floating point nor fixed), then the precision indicates the
  total number of significant digits.
 
  This setting remains in effect until the next change.
 
 
                                     -♦-