Logo 
Search:

Assembly Language Articles

Submit Article
Home » Articles » Assembly Language » Homework HelpRSS Feeds

PROGRAM TO FIND THE ADDITION OF N 8 BIT NO

Posted By: Adel Fischer     Category: Assembly Language     Views: 30247

WRITE A PROGRAM TO FIND THE ADDITION OF N 8 BIT NO.

Code for PROGRAM TO FIND THE ADDITION OF N 8 BIT NO in Assembly Language

DATA SEGMENT
A DB 1,2,3,4,5,6,7,8,9,10
DATA ENDS
CODE SEGMENT
         ASSUME DS:DATA,CS:CODE
START:
        MOV AX,DATA
        MOV DS,AX
        MOV CL,10
        LEA BX,A
        MOV AH,00
        MOV AL,00
    L1: ADD AL,BYTE PTR[BX]
        INC BX
        DEC CL
        CMP CL,00
        JNZ L1
        MOV AH,4CH
        INT 21
CODE ENDS
END START

;OUTPUT:->
-R
AX=0000  BX=0000  CX=002C  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0B98  ES=0B98  SS=0BA8  CS=0BA9  IP=0000   NV UP EI PL NZ NA PO NC
0BA9:0000 B8A80B        MOV     AX,0BA8
-T

AX=0BA8  BX=0000  CX=002C  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0B98  ES=0B98  SS=0BA8  CS=0BA9  IP=0003   NV UP EI PL NZ NA PO NC
0BA9:0003 8ED8          MOV     DS,AX
-T

AX=0BA8  BX=0000  CX=002C  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0BA8  ES=0B98  SS=0BA8  CS=0BA9  IP=0005   NV UP EI PL NZ NA PO NC
0BA9:0005 B10A          MOV     CL,0A
-T

AX=0BA8  BX=0000  CX=000A  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0BA8  ES=0B98  SS=0BA8  CS=0BA9  IP=0007   NV UP EI PL NZ NA PO NC
0BA9:0007 BB0000        MOV     BX,0000
-T

AX=0BA8  BX=0000  CX=000A  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0BA8  ES=0B98  SS=0BA8  CS=0BA9  IP=000A   NV UP EI PL NZ NA PO NC
0BA9:000A B400          MOV     AH,00
-G CS: 0018

AX=0037  BX=000A  CX=0000  DX=0000  SP=0000  BP=0000  SI=0000  DI=0000
DS=0BA8  ES=0B98  SS=0BA8  CS=0BA9  IP=0018   NV UP EI PL ZR NA PE NC
0BA9:0018 B44C          MOV     AH,4C
  
Share: 


Didn't find what you were looking for? Find more on PROGRAM TO FIND THE ADDITION OF N 8 BIT NO Or get search suggestion and latest updates.

Adel Fischer
Adel Fischer author of PROGRAM TO FIND THE ADDITION OF N 8 BIT NO is from Frankfurt, Germany.
 
View All Articles

 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
Siby Xavier from India Comment on: Apr 11
please check this link for sample programs
itsourtech.blogs...ot.in/.../...ith-8086_8654.html

View All Comments