Source Code for Lab #3
//
// lab03.cpp. This program reads a temperature in Fahrenheit
// and calculates the equivalent Celsius temperature.
//
#include <iostream>
using namespace std ;
int main(void)
{
int Fahrenheit, // temperature in Fahrenheit
Celsius; // temperature in Celsius
cout << "This program converts a temperature in" << endl ;
cout << "Fahrenheit to Celsius and vice versa." << endl ;
cout << "All measurements are in whole numbers." << endl << endl ;
cout << "Please enter a Fahrenheit temperature: ";
cin >> Fahrenheit;
/*
The assignment statement below computes the Celsius temperature
corresponding to the Fahrenheit temperature, and stores the value into
the variable called Celsius.
Fill in the formula needed on the Right Hand Side below.
*/
Celsius = ;
cout << Fahrenheit << " degrees Fahrenheit = "
<< Celsius << " degrees Celsius" << endl ;
return 0;
}