Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

IV. (15 points) Programming A memory variable dictionary consists of multiple words according to the two rules as follows . for each word, the length

image text in transcribed

IV. (15 points) Programming A memory variable dictionary consists of multiple words according to the two rules as follows . for each word, the length of the word is followed by the actual characters a special symbol IAh is used to mark the end of the dictionary Below are two dictionary examples dictionary db 8, "Holidays ". IAh; one 8-character word defined dictionary db 5, "Happy"8, "Holidays ". IAh; two words with 5 and 8 characters 4.1 (2 pts) Write an 8086 assembler directive to define exactly three words of your choice in dictionary in .data section. 4.2 (3 pts) Make corrections about the following program so that it will print the first word in the dictionary onto the screen under DOS. Consider only the parts in bold model small stack 100h data dictionary db 256 dup (?); assume multiple words to be defined here firstWord db 256 dup (?); will store the first word code start mov ax, @data mov ds, ax mov si, offset dictionary mov di, offset firstString mov cx, Isil copy: mov byte ptr [dil, byte ptr [si] inc si inc di loop copy print: mov dx, offset firstString mov ah, 09h int 21h mov ax, 4c00h int 21h end start IV. (15 points) Programming A memory variable dictionary consists of multiple words according to the two rules as follows . for each word, the length of the word is followed by the actual characters a special symbol IAh is used to mark the end of the dictionary Below are two dictionary examples dictionary db 8, "Holidays ". IAh; one 8-character word defined dictionary db 5, "Happy"8, "Holidays ". IAh; two words with 5 and 8 characters 4.1 (2 pts) Write an 8086 assembler directive to define exactly three words of your choice in dictionary in .data section. 4.2 (3 pts) Make corrections about the following program so that it will print the first word in the dictionary onto the screen under DOS. Consider only the parts in bold model small stack 100h data dictionary db 256 dup (?); assume multiple words to be defined here firstWord db 256 dup (?); will store the first word code start mov ax, @data mov ds, ax mov si, offset dictionary mov di, offset firstString mov cx, Isil copy: mov byte ptr [dil, byte ptr [si] inc si inc di loop copy print: mov dx, offset firstString mov ah, 09h int 21h mov ax, 4c00h int 21h end start

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_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

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

Get Started

Students also viewed these Databases questions

Question

Compare the different types of employee separation actions.

Answered: 1 week ago

Question

Assess alternative dispute resolution methods.

Answered: 1 week ago

Question

Distinguish between intrinsic and extrinsic rewards.

Answered: 1 week ago