Wednesday, October 28, 2020

8086 Assembly Program to Sort Series / Array in Ascending order in 8086

In this post you will get the program code to sort the series or an array in ascending order using the microprocessor 8086 !! So,lets Begin....

data segment

arr1 dw 44h,66h,91h,20h,33h,60h,88h,50h

count dw 07h

data ends

code segment

assume cs:code, ds:data

mov ax,data

mov ds,ax

mov dx,count

iter: mov bx,offset arr1

mov cx,dx

comps: mov ax,[bx]

cmp ax,[bx+02h]

jc skip

xchg ax, [bx+02h]

mov [bx],ax

skip: inc bx

inc bx

loop comps

dec dx

jnz iter

code ends

end start

Programs:-

For many other Language Programs of microprocessor 8086, C++ , C , Data Structures visit our  BLOG 

There are programs of Object-Oriented Programing, Operators (logical, arithmethic ,relational,etc) ,exception handeling , inheritance ,string operations ,etc

No comments:

Post a Comment