Not sure I understand what is going on with setw().
I would expect the program below to output something like this
77
77
77
77
Instead, it does this:
77
77
77
77
77
77
Why are the first three 77's not indented?
#include "utility.h"
// setw example
#include <iostream>
#include <iomanip>
using namespace std;
int main ()
{
for(int i = 0; i < 10; i++)
{
cout << setw (i);
cout << 77 << endl;
}
return 0;
}