| 
iostream hierarchy showpoint / noshowpoint  | 
| cplusplus.com | 
 Set/Unset showpoint format flag 
 
showpoint sets the format flag to always show the decimal point when representing floating-point values.
 
noshowpoint unsets this flag, inserting the decimal point only when necessary.
Parameters.
 Return Value.
 
A reference to the stream object.
 Example.
// modify showpoint flag
#include <iostream>
using namespace std;
int main () {
  double d, pi;
  d=10.0;
  pi=3.1416;
  cout.precision (5);
  cout << hex << showpoint << d << '\t' << pi << endl;
  cout << hex << noshowpoint << d << '\t' << pi << endl;
  return 0;
}
The execution of this example shall display:
 10.000  3.1416
 10      3.1416
 See also.
 
flags,
setf,
unsetf
 
ios_base class