Review Questions

1:What role does the iostream file play in C++ I/O?
2:Why does typing a number such as 121 as input require a program to make a conversion?
3:What's the difference between the standard output and the standard error?
4:Why is cout able to display various C++ types without being provided explicit instructions for each type?
5:What feature of the output method definitions allows you to concatenate output?
6:Write a program that requests an integer and then displays it in decimal, octal, and hexadecimal form. Display each form on the same line in fields that are 15 characters wide, and use the C++ number base prefixes.
7:Write a program that requests the information shown below and that formats it as shown:
Enter your name: Billy Gruff ...

Get C++ Primer Plus, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.