Example 1
ncout << “The sum of 6 and 15 is “ << setw(3)
n          << 21 << endl;
nThe setw(3) field width manipulator included in the stream of data passed to cout is used to set the displayed field width.
nThe 3 in this manipulator sets the default field width for the next number in the stream to 3 spaces.
nThis field setting causes 21 to be displayed in a field of 3 spaces, which includes one blank space and the number 21.