Achrine / Ch-2-Hw

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Chapter 2: Input is hardcoded. edit Chapter 3: Input structure. We take the user input, or something. There's probably 15 or 30...problems to do?

In the book, an pg 111 take notes. It might just be in the slides. The way a file is printed is called it's formating, ie the appearance. Formating is a change in attire, not a change in content.

To format with cout object, #include // Required for setw, or, set-width, I'm assuming.

setw appears to be a method or function, taking an argument.

< cout << setw(6) << num << setw(6);

For formatting floats(?): we use the object/function/method setprecision(#) Where # is, we define how precise the output is.

About


Languages

Language:C++ 100.0%