C Activity
Temperature Conversion Chart

Overview

This is a short C programming exercise that will introduce you to some core
C programming constructs: comments, variable declaration, arithmetic
expressions, loops and formatted output. Reference the introductory
slides shown in class and/or the C resources included on the course website.

Activity

Part 1

Write a C program that produces a chart of temperature conversions from
Fahrenheit to Celsius. Your program should output the Celsius conversion of Fahrenheit
temperatures in the range of 0-300 degrees F in increments of 20 degrees.
The output should look exactly like this:

Use the formula of C = (5/9)( F -32 ) to perform the
conversion. Note that all arithmetic is to be done using
integer
variables. In C, the division of two integer numbers truncates the fractional remainder.

Name your C program chart1.c in a directory named TempConvert

Create an ActivityJournal.txt. First estimate the time you will need to complete the program and complete your plan.
Then fill in all remaining sections as you work on the activity.

Keep track of the number of times you attempt to compile your program and
generate a compiler error of any type. Note that number in the ActivityJournal.txt
along with the actual time to complete the program.

When you get a clean compile, the executable program will be named chart1
(that's what the -o (output) option is for). To test your program, execute the following command:
./chart1

The command runs your program; the
./
forces the command language interpreter (bash, or the Bourne-Again Shell)
to look in the current directory rather than the directories for standard system commands.

Submit your source file chart1.c and ActivityJournal.txt
in a directory named TempConvert to your Git pushbox.

Complete this Part before beginning Part 2.

Part 2

First estimate your completion time in the Activity Journal and then complete the Plan.
Copy chart1.c to a new file called chart2.c. In this new file
perfom the conversion calculation using floating point variables.
The output should look exactly like this (note the change in justification from chart1.c):