Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The following Assembly function needs to take negative sign number. Add the external code in places where it goes in the function. External Code: //

The following Assembly function needs to take negative sign number. Add the external code in places where it goes in the function.

External Code: // Implement this inside the function so it can take negative number. You don't need to run this program just put the external code where it goes inside the function

cmp byte ptr SIGNO,-1 jnz ANOTHER mul SIGNO mov byte ptr STRING[di],'-' inc di

FUNCTION:

UNSIGNED_INT_TO_STRING PROC

mov ax, UNSIGNED_INT mov bx, 10 mov di, 0h

ANOTHER: mov dx, 0h div bx add dl, '0' mov STRING[di], dl inc di cmp ax, 0h jnz ANOTHER mov STRING[di], '$'

dec di mov si, 0

OTHER: mov ch, STRING[di] mov cl, STRING[si] mov STRING[di], cl mov STRING[si], ch dec di inc si cmp si, di jb OTHER

RET UNSIGNED_INT_TO_STRING ENDP

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

4 3 6 .

Answered: 1 week ago

Question

1. The evaluation results can be used to change the program.

Answered: 1 week ago

Question

5. To determine the financial benefits and costs of the program.

Answered: 1 week ago