Professional Documents
Culture Documents
Sorting A Series of 10 Numbers: Flowchart
Sorting A Series of 10 Numbers: Flowchart
Sorting A Series of 10 Numbers: Flowchart
No : 11 Date:
Venue: MPMC lab (A3 –TF10 Time:
backside) Branch/year:E2-ECE
ID.No: Section: SG-02
Name:
Sorting a series of 10 numbers
AIM:
TO Write an assembly language programme to SORT a series of a
10 numbers from 20,000H in ascending order using 8086.
APPARATUS
Sl.no Name of the Specification Quantity
equipment
1 Micro processor kit 8086 1
2 Power supply 5V, DC 1
3 Key board - 1
ALGORITHM:
1. Initia1lise segment address DS=2000H.
FLOWCHART:
-
PROGRAM:
CODE SEGMENT
ASSUME CS:CODE
MOV AX,2000H
MOV DS,AX
MOV CH,09H
BCK2: MOV SI,0000H
MOV CL,09H
BCK1: MOV AX,[SI]
CMP AH,AL
JNC SKIP
XCHG AL,AH
MOV [SI],AX
SKIP: INC SI
DEC CH
JNZ BCK2
INT 03H
CODE ENDS
END
INPUT
ADRESS DATA
20000 01
20001 05
20002 09
20003 07
20004 03
20005 06
20006 02
20007 04
20008 10
20009 08
OUPUT
ADRESS DATA
20000 01
20001 02
20002 03
20003 04
20004 05
20005 06
20006 07
20007 08
20008 09
20009 10