Question: Write an assembly language program (windows32) that will do the following: First, the program should prompt the user to enter 10 positive integers less than

Write an assembly language program (windows32) that will do the following:

  1. First, the program should prompt the user to enter 10 positive integers less than or equal to 100, one at a time. The program should store these values into an array as they are entered in the order received. Your program should guard against non-positive integers (zero is not a positive integer) and integers above 100. Your program should use a loop to accomplish this (repeatedly informing the user of the invalid input and prompting for a valid input).
  2. Only after step 1 is completed should the program then display the contents of the array, in the order they were entered, all in one single output. Use a loop to form the output string.
  3. Then the program should shift all the values in the array one place to the left, the first element should wrap around and become the last element.
  4. Then the program should display the contents of the array again, in the new shifted order, all in one single output.
  5. Then the program should scan the array and report the index (0, 1, 2, ...,, or 9) of the smallest element in the array.

Notes:

  • Each step above should be completed as a stand-alone task. Do NOT attempt to combine steps.

  • You MUST use exactly one numerical array. No more. Of course, you will have strings (or arrays of characters for the display). That's OK.

  • Your output should have message headers that are informative as to what you are displaying (e.g. "The array as entered", "The shifted array", etc.)

  • You MUST include ample, meaningful comments. Points will be deducted for hard to read code. Comments really help readability.

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!