
Chapter 5: Prelab Assignment
Conditions, Logical Expressions, and Selection Control Structures | 107
Name __________________________________________ Date _______________________
Section _________________________________________
Examine program Convert and answer the questions in Exercises 1 through 3.
// Program Convert converts a temperature from Fahrenheit to
// Celsius or a temperature from Celsius to Fahrenheit
// depending on whether the user enters an F or a C.
#include <iostream>
using namespace std;
int main ()
{
char letter; // Place to store input letter
int tempIn; // Temperature to be converted
int tempOut; // Converted temperature
cout <<"Input ...