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:
- 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).
- 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.
- 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.
- Then the program should display the contents of the array again, in the new shifted order, all in one single output.
- 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
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started