You are on page 1of 5

Question no.

Ax=Roll number=32

Ah=first letter of name=A

mov ax,32

add ah,'a'

clc

xor ah,al

mov cl,4

shr al,cl

rcr ah,cl

Use emulator:
Question no.3:

a) AND AX,AAAAh
b) OR BL,81h
c) NOT WORD1

Question no.4

Mov ax,E6E6

Move dl,0

Mov bl,0

Mov cl,2

L1: shl al,1

Rcl dl,1

LoopL1

Mov cl,2

L2: shl al,1

Rcr bl,1

LoopL2

Mov cl,2

L3: shr dl,1

rcr al,1

loopL3

mov cl,2

L4: shr bl,1


Rcr al,1

loopL4

mov dl=0

mov bl=0

mov cl,2

L5: shr al,1

Rcl dl,1

LoopL5

Mov cl,2

L6: shr al,1

Rcl bl,1

LoopL6

Mov cl,2

L7: shr dl,1

rcl al,1

loopL7

mov cl,2

L8: shr bl,1

Rcl al,1

LoopL8

Mov dl=0

Mov bl=0

Mov cl,2
L9: shl ah,1

Rcl dl,1

loopL9

mov cl,2

L10: shl ah,1

Rcl bl,1

loopL10

mov cl,2
L11: shr dl,1

rcr ah,1

loopL11

mov cl,2

L12: shr bl,1

Rcr ah,1

loopL12

mov cl,2

L13: shr ah,1

Rcl dl,1

loopL13

mov cl,2

L14: shr ah,1

Rcl bl,1

loopL14
L15: shr dl,1

Rcl ah,1

loopL15
mov cl,2

L16: shr bl,1

Rcl ah,1

loopL16

mov ax,4c00

You might also like