Midterm 2 Flashcards
Library containing text setting commands (width, precision, etc.)
include
Command to set fixed notation
cout.set(ios::fixed);
Command to set scientific notation
cout.set(ios::scientific);
Command to set precision
cout.precision(6);
In-line command to set fixed notation
cout «_space;fixed «
In-line command to set scientific notation
cout «_space;scientific «
In-line command to set precision
cout «_space;setprecision(6) «
In-line command to set width
cout «_space;setw(6) «
Function parameter
In function definition
Function argument
In function call
ASCII code for space
32
ASCII code for 0
48
ASCII code for A
65
ASCII code for a
97
Command to stop fixed notation
cout.unsetf(ios::fixed);
What to do if you want 6 after the decimal?
Include cout.unset(ios::fixed); or in-line fixed
What to do if you want 6 sig figs?
Do not include fixed, or do cout.unset(ios::fixed);