assume cs:code,ss:stack
stack segment
db '0,0,0,0,0,0,0,0'
stack ends
code segment
start:mov ax,stack
mov ss,ax
mov sp,8
mov ax,0
call far ptr s
inc ax
s: pop ax
add ax,ax
pop bx
add ax,bx
mov ax,4c00h
int 21h
code ends
end start
****************************************
****************************************
1 assume cs:code,ss:stack
2
3 stack segment
4 db '0,0,0,0,0,0,0,0'
5 stack ends
6
7 code segment
8 start:mov ax,stack
9 mov ss,ax
10 mov sp,8
11 mov ax,0
12 call far ptr s
13 inc ax
14 s: pop ax
15 add ax,ax
16 pop bx
17 add ax,bx
18 mov ax,4c00h
19 int 21h
20 code ends
21 end start |