Due by noon on Saturday, September 25, 1999 / 8am Monday, September 27, 1999 In this assignment you will build a more full-featured version of the quadratic equation solver designed in the lecture notes. Your submission will be in two parts. The program will be submitted in the usual way (and should be named Quadratic). You must also submit a top-down-design of the program of the sort we created in the lecture. This part should be submitted on paper. You should submit it by dropping it in the box outside Professor Fleck's door by noon on Saturday the 25th. (Note this is two days before the program is due.) Since you have to do the top-down-design anyway, you might as well do it first! To see how your program should behave, run our on-line simulator. Make your program mimic its behavior as closely as possible. If you want to try the simulator more than once (to test different behaviors) just use the "reload" option on the page that pops up for the program. The Problem: Prompt the user to enter the coefficients of the quadratic equation. Print the roots of the equation, taking into account the following issues:
Here is some sample output from the sample solution:
[1:01pm] hodas@orion (~): java Quadratic
|
Last modified Sept 16 for Fall 99 cs5 by fleck@cs.hmc.edu
This page copyright ©1998 by Joshua S. Hodas. It was built with Frontier on a Macintosh . Last rebuilt on Tue, Sep 8, 1998 at 10:13:10 PM. | |
http://www.cs.hmc.edu/~hodas/courses/cs5/week_04/homework.html | |