- It is used to read character data only !! (not integers, floats, etc.)
- It is called like this: cin.get(ch);
(ch must be a variable of type char)
- Only one character is read at a time (the next character in the input stream) and is stored in the variable ch
- Whitespaces are not skipped this time !!!
- It is used to skip (read and discard) characters in the input stream
- It is called like this: cin.ignore(200,'\n');
(skip the next 200 characters or keep skipping characters until a newline character
is read)
<Table from page 142>
- A program should print enough messages to inform the user about what type of data he is supposed to enter (input prompts)
- A program should also print out all the data values entered so that the user can
verify that he/she entered them correctly (echo printing)
<Program segment from page 143>