Title :
Write a assembly language program to display two messages on the screen for 20 time.
Algorithm :
1. Start the process
2. Declare the model as small
3. Take 100 sized stack
4. Declare the messages to display in 20 times
5. Load the effective address of the message in Dx register
6. Display and execute the message form Dx
7. Return to DOS mode
8. End of process.
Programming Code :
model small
stack 100h
data
msg1 db ‘Bangladesh University $’
msg2 db ‘Dhaka $’
code
main proc
mov ax, @ data
mov ds, ax
lea dx, msg1
lab1:
int 21h
loop lab1
mov cx,20
lea dx, msg2
mov ah, 9
lab2:
int 21h
loop lab2
mov ah, 4ch
int 21h
main endp
end main
Output :
Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka Dhaka
Algorithm stand for step by step work. This site will give you basic knowledge about algorithms.
Tuesday, October 5, 2010
Subscribe to:
Post Comments (Atom)
Simple and Complete E-commerce PL/SQL Code
This is a Database of e-commerce solution. This database is quite simple but complete one. The script (.sql file) contain all the nece...
-
Algorithm : Step 1: Start the process. Step 2: Declare the model as small. Step 3: Take 100 size stacks. Step 4: Declare the message to disp...
-
1.Algorithm of find the Factorial Number: 1.Start 2. (Input)Read N 3. Set Product=1 Mult=N 4.(Repeat This L...
-
Program Name: Minimum value #include #include int a[12],j,k,n,i,loc; void main() { clrscr(); printf("\r\n How many elements in Array??...
No comments:
Post a Comment