School of Engineering and Applied Science
Department of Computer Science
CSci 49 -- Introduction to C Computing
http://www.seas.gwu.edu/~csci49/spring06
Prof. Michael B. Feldman
mfeldman@gwu.edu

Project #2
Due Date: Start of lecture, Thursday, Feb. 9, 2006

The objective of this first project is to do a simple software development project, as described in the online document Systematic Software Development.

Problem Specification:

From the so-called "Y2K problem" in the year 2000, we know that an important function of software systems is keeping track of dates and times. One common way of representing the time of day internally (to the nearest second) is as an integer number in the range 0 to 86399. (Why is 86399 the maximum value?) This value indicates the number of seconds that have elapsed since midnight on the given day.

Since people are not very good at keeping time by seconds, it is helpful to convert this single value into a set of three values that represent the hours, minutes, and seconds of the current time. We will use a 24-hour representation of the time; for example, 6:21:36 PM is given as 18:21:36.

Your task is to produce a program that will prompt the user for the number of seconds since midnight, and then compute and display the time of day in 24-hour form. If the minutes or seconds are 9 or less, make sure to display a leading zero. The 3rd week reading will help you work out how to format the numbers properly. Call this program TimeOfDay.

What to submit:

You must follow the process given in Systematic Software Development. Submit Your grade will be calculated on a 20-point basis, as follows:

Extra credit bonus:

This extra credit bonus is to provide an incentive for starting your project early in the week.If you e-mail your "framework" listing file to Prof. Feldman, and the time stamp on the e-mail is no later than 5 PM, Monday, Feb. 6, 2006, you will be awarded 2 extra project points. The "framework" must be a listing (.txt) file, with no compilation errors, that contains the declared variables, and a set of comments inserted for the main algorithm steps.  E-mail the file as you did the survey form, e.g., pine mfeldman <TimeOfDay.txt

MBF 1/30/06