Question: Examine the following code outline. What is the first change you should make to include a function description? Line 1 : Greet the user. Line

Examine the following code outline. What is the first change you should make to include a function description?
Line 1: Greet the user.
Line 2: Allow the user to choose to enter a number pair or exit.
Line 3: If the user chooses to exit, terminate the program.
Line 4: If the user chooses to enter two numbers, ask the user to enter two numbers.
Line 5: Multiply the numbers.
Line 6: Display a message that includes the product.
Line 7: Allow the user to choose to enter another number pair or exit.
Line 8: If the user chooses to exit, terminate the program.
Line 9: If the user chooses to enter two more numbers, ask the user to enter two numbers.
Line 10: Multiply the numbers.
Line 11: Display a message that includes the product.
Line 12: Allow the user to choose to enter another number pair or exit.
...[continues in a similar manner]
Group of answer choices
Move lines 5 and 6 to the top of the outline.
Place lines 2 through 6 within a repeating group (loop).
Rewrite lines 3 and 4 as a single line, If the user chooses to exit, terminate the program; else ask the user to enter two numbers.
Rewrite lines 5 and 6 as a single line, Apply multiplication and display behavior to the numbers.

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!