
Lesson 5-3: if-then Statements
112 | Chapter 5
Name __________________________________________ Date _______________________
Section _________________________________________
Use program Pressure for the exercises in this lesson. This program prompts for and reads an
integer value, and then prints a message based on this value.
// Program Pressure prints appropriate messages based on a
// pressure reading input from the keyboard.
#include <iostream>
using namespace std;
main ()
{
int pressure;
cout << "Enter an integer pressure reading. "
<< " Press Return." << endl;
cin >> pressure;
/* FILL IN code appropriate to exercise */
return 0;
}
Exercise 1: Insert a statement ...