Question: / / Name: [ Your Name ] / / Lab Name: [ Your Lab Name ] / / Date: [ Date ] / / Declare

// Name: [Your Name]// Lab Name: [Your Lab Name]// Date: [Date]// Declare variablesinteger number;integer largest =-9999999; // Priming read for largestinteger smallest =9999999; // Priming read for smallestinteger sum =0;// Outside loop to keep the program running until told to stoprepeat // Inside loop to ask for input of a number, positive or negative repeat // Input number count should be unlimited Enter a number: number; // Input of a zero (0) terminates inside loop if number =0 then Exit loop; end if // Update largest and smallest if necessary if number > largest then largest = number; end if if number < smallest then smallest = number; end if // Add number to sum sum = sum + number; until false; // Display the largest and smallest number entered and the sum of the numbers Display "The largest number you entered is:", largest; Display "The smallest number you entered is:", smallest; Display "The sum of the numbers is:", sum; // Ask if the user wants to enter a new set of numbers Enter "Do you want to enter a new set of numbers? (Y/N):" choice; if choice ="N" then Exit loop; end ifuntil false;

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 Programming Questions!