Saturday, May 18, 2019

8086 Assembly Program to find the length of a String

Today we will see the 8086 program to find the length of a String using 
8086 microprocessor assembly language!!


For many other Assembly Programs 8086, data structures, C etc.... Related to MSBTE, Computer engineering, IT field visit our  BLOG  .


Let's Begin!!


data segment
str1 db ” hello”
len db ?
 data ends
code segment
start : assume  cs :code,  ds :data
mov ax , data
mov ds ,ax
LEA si ,str1
up: mov al, [si]
cmp al , “$”
 jz exit1
inc si
inc len
jmp up
exit1  : mov ah,4ch
int 21h
code ends
end start
Programs:-


For many other Assembly Language  Programs related to microprocessor 8086, C++ ,Data Structures visit our  BLOG 

There are programs of largest ,smallest ,division ,multiplication,odd/even,block operation ,string operations,BCD ,etc


No comments:

Post a Comment