Question: Using visual studio 2015 Write a program that clears the screen, locates the cursor near the middle of the screen, prompt the userto enter three
Using visual studio 2015
Write a program that clears the screen, locates the cursor near the middle of the screen, prompt the userto enter three signed integers:
Enter Signed Integer:
-Assign those values to val2, val3, and val4
.
-val1, val2, val3 and val4 are 32-bitmemory signed integers
-Pass those values to a subroutine that implements the following expression:
val1 = (val2-val3)*(val4/val2)-(val3*3)
-To access the values in the caller frame, use EBP (remember EBP is created at the callee side).
-The calculated expression result needs to be assigned to val1 at the caller side.
-The calculated expression result needs to be displayed on console screen from main subroutine
.
-Name the subroutine IntegerArithmeticProc
.
-When calling or creating the IntegerArithmeticProc subroutine , you are not allowed to use anyof the following directives: invoke, addr, proc with lists, and proto or proto with lists
-Use the appropriate multiplication and division instructions
.
-Use the CBW, CWD,or CDQ instructions when needed
.
-For (val4 *3),you must usethemultwo operandsformat.-Run your program usingthedebuggerto verifyyour answers
.
Use Step Into instead of Step Over to keep track of
the stack,
ESP, EBP, EIP during
debugging
.
To access the stack memory,
copy the value of ESP from the register window and past it in
the search text box in the memory windo
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
