programming

posted by .

Your goal for this project is to write an unsigned 16-bit software implementation of both the multiplier and the divider architectures found in the book.

Input/Output
You are required to read two unsigned integers from the console. The valid range for both values is 0 to 65535. Your program will multiply and divide them and provide the product, quotient, and remainder. Your program must include a trap (i.e. a notification and graceful exit) for divide-by-zero.

Here’s an example run:
Enter an integer: 10
Enter an integer: 4
Product is 40
Quotient is 2
Remainder is 2

  • programming -

    For you benefit, I suggest you start with a pseudocode or a draft coding even if it does not compile.
    From the starting point, we can better help you without doing it for you.

  • programming -

    I got the code and it works..............its just that I don't know how to do it wihtout using the "mult" and "div" operands.

Respond to this Question

First Name
School Subject
Your Answer

Similar Questions

  1. programming

    I am supposed to modify this program so it begins by asking the user for the number of values. The program then uses a loop to read the specified number of values and then display their average. program is below that i worked on in …
  2. programming

    write a program that maintains two parallel arrays. after th arrays have been loaded the program should behave as a login screen prompting for username and password. the program should respond three output messages. if username does …
  3. programming

    Consider the following selection statement where X is an integer test score between 0 and 100. input X if (0<=X and X<49) Output "you fail" Else if (50<=X and X <70) Output "your grade is" X Output " you did OK" Else if …
  4. Computers

    I have project i need your help. this is the Project Description In this project, you will design a complete arithmetic unit of a microprocessor which can do addition, subtraction, multiplication, and division of two 2-bit binary numbers …
  5. computers

    Suppose the information portion of packet (D in figure 5.4) contains 10 bytes consisting of the 8-bit unsigned binary ASCII representation of string “Link Layer.” Compute the internet checksum for this data. Can someone explain …
  6. Computer Science

    Overview The purpose of the assignment is to develop a basic understanding and skills programming of input/output ports and device polling. The assignment examines hardware polled input from a push button. Assignment 1 The assignment …
  7. programming

    Consider the following input and output: INPUT: (((5 + 1) – (7 – 4)) / (11 – 8)) OUTPUT: 5 1 + 7 4 – – 11 8 - / 2.1. What variables do you need to consider for the input?
  8. Computer Ntwrks

    Suppose the information portion of a packet (D in Figure 5.3) contains 10 bytes consisting of the 8-bit unsigned binary ASCII representation of string “Networking.” Compute the Internet checksum for this data.
  9. discrete math

    Q: Consider a digital circuit that reads an n-bit input string and writes a 1bit output. Two circuits are considered different if they have a different output for some input string, otherwise they are considered the same (i.e. two …
  10. discrete math

    Q: Consider a digital circuit that reads an n-bit input string and writes a 1bit output. Two circuits are considered different if they have a different output for some input string, otherwise they are considered the same (i.e. two …

More Similar Questions