Question: Design for a bulletproof Multiply Write and test thoroughly a MARIE x times y multiply program that will: (1) always produce a correct result or

Design for a "bulletproof" Multiply

Write and test thoroughly a MARIE x times y multiply program that will:

(1) always produce a correct result or flag an error condition (if a correct result is not possible);

(2) be as efficient as possible -- i.e. accomplish its work by executing the least number of total instructions;

(3) accept and correctly process any combination of positive, zero, or negative integers given as keyboard input by the user;

(4) clean up after itself and be ready to receive the next set of inputs without having to restart the program;

(5) halt the program when the user enters both x and y values as zero (i.e. user asks for zero times zero);

(6) detect and gracefully handle/report overflow and any other error conditions. (In planning your design, you need to plan how error situations will be displayed to the user given the constraints of the MARIE simulator.)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!