Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

Hitesh Vadgama 1712061

Rishi molia 1712063

FIBONACCI SERIES PROGRAM

Microsoft (R) Macro Assembler Version 5.10 4/12/19


09:53:38
Page
1-1

.model small
.data
0000 07 cnt db 07
0001 0008[ res db 8 dup(0)
00
]

.code
0000 B8 ---- R start: mov ax,@data //initialize DS
0003 8E D8 mov ds,ax //move ax contents to dx
0005 8A 0E 0000 R mov cl,cnt // move count to CL register
0009 BE 0500 mov SI ,500h // Set SI to 500H
000C B0 00 mov al,0 // reset AL to 0
000E 88 04 mov[si],al //Move AL to address of SI
0010 46 inc si // increment SI by 1
0011 B3 01 mov bl,01 // Move 01 to BL
0013 88 1C mov [SI],bl // Move BL to address of SI
0015 83 E9 02 sub cx,0002 // subtract 0002 from CX
0018 8A 44 FF up: mov al,[si-1] // move operand in address
SI-1 to AL
001B 02 04 add al,[si] // add operand stored in
address SI to AL
001D 46 inc si // increment SI by 1
001E 88 04 mov [si],al //move AL to Address of SI
0020 E2 F6 loop up
0022 B4 4C mov ah,4ch /* DOS BOX TERMINATION
0024 CD 21 int 21h COMMAND/*
end

Microsoft (R) Macro Assembler Version 5.10 4/12/19


09:53:38

Symbols-1

Segments and Groups:

N a m e Length Align Combine Class

DGROUP . . . . . . . . . . . . . GROUP
_DATA . . . . . . . . . . . . 0009 WORD PUBLIC 'DATA'
_TEXT . . . . . . . . . . . . . 0026 WORD PUBLIC 'CODE'

Symbols:

N a m e Type Value Attr

CNT . . . . . . . . . . . . . . L BYTE 0000 _DATA

RES . . . . . . . . . . . . . . L BYTE 0001 _DATA Length =


0008

START . . . . . . . . . . . . . L NEAR 0000 _TEXT

UP . . . . . . . . . . . . . . . L NEAR 0018 _TEXT

@CODE . . . . . . . . . . . . . TEXT _TEXT


@CODESIZE . . . . . . . . . . . TEXT 0
@CPU . . . . . . . . . . . . . . TEXT 0101h
@DATASIZE . . . . . . . . . . . TEXT 0
@FILENAME . . . . . . . . . . . TEXT febo
@VERSION . . . . . . . . . . . . TEXT 510

23 Source Lines
23 Total Lines
20 Symbols

46508 + 411888 Bytes symbol space free

0 Warning Errors
0 Severe Errors

OUTPUT:

You might also like