// IEA Oct 1995 // Example program - section 8.4 // Outputs a table of x and sin(x) // Uses manipulators for output #include #include #include void main() { float x; int i; cout << setiosflags(ios::fixed | ios::showpoint); for (i = 0; i <= 16; i++ ) { x = 0.1 * i; cout << setprecision(1) << setw(4) << x ; cout << setprecision(6) << setw(10) << sin(x) << endl; } }