I could use some help in figuring out how to format the output of my program when writing to a file.
Bit of code
outFile << sum << endl;
What I'd like to do is to align the output to the right and fill smaller values with either a space or . So the output file would look like
I've tried using iomanip with stuff like
outFile << sum;
But it returns an error stating something about converting longs to something else. I don't recall the exact error. I'd appreciate any help or ideas.