C++ examples for File Stream:cout
The most common manipulators and their corresponding meanings are shown in the following table.
Manipulator | Member Function | Description |
---|---|---|
dec | setf(dec) | Sets radix to 10 |
hex | setf(hex) | Sets radix to 16 |
oct | setf(oct) | Sets radix to 8 |
setfill(c) | fill(c) | Sets the fill character to c |
setprecision(n) | precision(n) | Sets display precision to n |
setw(n) | width(n) | Sets width of field to n characters* |