Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write and test a MASM program that calculates the factors of each number within a range of numbers and indicates which numbers are prime. 1

Write and test a MASM program that calculates the factors of each number within a range of numbers and indicates which numbers are prime.
1. Display your name and program title on the output screen.
2. Display instructions for the user.
3. Get the users name.
4. Prompt the user to enter two values representing the lower and upper bound for the range of integers for which factors are calculated. Advise the user to enter values between 1 and 1000.
5. Get and validate the user input. If the input is invalid re-prompt the user for input.
6. Calculate and display all of the factors in the range. If the integer is prime also display this for the user.
7. After displaying the list of numbers and factors prompt the user to go again.
0=No : go to step 8
1=Yes : go to step 4
8. When the user chooses to terminate the program display a parting message including the users name.
Requirements:
1. The main procedure must be modularized into commented logical sections (procedures are not required this time).
2. The programmers name and the users name must appear in the output.
3. The program must be fully documented. This includes a complete header block for identification, description, etc., and a comment outline to explain each section of code.
4. The upper limit of 1000 should be defined as a constant.
5. The usual requirements regarding documentation, readability, user-friendliness, etc., apply.
6. Submit your text code file (.asm) to Canvas by the due date.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

Use social media to advantage

Answered: 1 week ago

Question

2 What are the implications for logistics strategy?

Answered: 1 week ago