>
CS 1323 Honors, Fall 1996

Individual Project 6

Interactive Data Entry

Due Monday, November 4, 4:30pm

What to Hand In (see also: example project solution)

Project Description

Write a program that creates a file suitable for processing by the program of Team Project C from data supplied interactively from the keyboard.

The file created must contain no lines that would cause the program from Team Project C to fail. That is, city/state/zipcode lines, date lines, and item lines must be in a form recognizable by the tuple-forming functions of Individual Projects 5A, 5B, and 5C.

To accomplish this, prompt individually for elements that have constraints on the form in which they must be entered, check to make sure they meet the constraints, and ask for re-entry from the keyboard when they fail to meet constraints. For example, you might ask for the city, state, and zipcode separately, rather than as a single line. Then, upon retrieving, say, the state entry, check to make sure it passes muster, and ask for re-entry if it fails. You could treat the zipcode and other constrained parts of entries in a similar way.

Design your program's dialog with the person at the keyboard to be polite and concise.

Construct the program in such a way that it allows any number of customer orders to be entered, and such that each customer order may contain any number of items.

Ground Rules