1. Using only MOV, ADD, SUB, INC, DEC and NEG, translate the following high-level statements into assembly language. A, B and C are word variables:
a. A = B – A
b. A = -(A+1)
c. C = A + B
d. B = 3-B+7
e. A = 5-A
2. Which of the following names are legal in IBM PC assembly language?
c. Two Words
g. T =
3. Which of the following are legal numbers? If they are legal, tell whether they are binary, decimal, or hex numbers
3. Tell whether each of the following instructions is legal or illegal. W1 and W2 are word variables, and B1 and B2 are byte variables.
a. Mov DS,AX
b. Mov DS,1000h
c. Mov CS,ES
d. Mov W1,DS
e. XCHG W1,W2
f. SUB 5, B1
g. ADD B1, B2
h. ADD Al, 256
i. Mov W1,B1
4. Write instructions (not a complete program) to do the following:
a. Read a character, and display it at the same position on the same line.
b. Take two hex values, store them in two variables and exchange the values of two variables.
Recently Asked Questions
- What is the time value of money? Explain the relationship of discounting and compounding. Provide an example of how these concepts might take on importance in
- I need help with my microbiology midterm paper! these are the instructions! "Some scientists are concerned that genetic engineering allows humans to tamper
- please highlight the portuguese congest of the african states and give every step in the stating.please make sure there is no plagarism at all.