Question

Write a NEAR subroutine using 8086 assembly Language (with proper comments) that returns the average value of the values stored in a byte array of length 3. All three values of the byte array are passed to the subroutine in the stack. You should write both the calling program and subroutine.

07 Aug 2023
Answer :
Word Count : 482

Below is the assembly code for both the calling program and the subroutine to calculate the average value of a byte array of length 3, using the 8086 assembly language. I'll provide comments to explain each part of the code.

; Calling Program
ORG 100h    ; Set the origin address

MOV AH, 0   ; Clear AH register
MOV AL, 20  ; Load first value into AL
PUSH AX     ; Push first value onto the stack

MOV AL, 30  ; Load second value into AL
PUSH AX     ; Push second value onto the stack

MOV AL, 40  ; Load third value into AL
PUSH AX     ; Push third ______ __________ ____ _________ ______ ______ ________ _______ _____ ________ _____.
_______ _____ _________ _____ ________ ________ _____.
_______ ______ ___ _________ __________ _______ __________ __________ _____.
______ ____ _______ ______ _____ ___ ____ __________.
______ _____ _______ ___ _______.
__________ ______ _______ _________ ______ ___ ________ ________ ____.
____ ____ _________ ____ ____ _______ __________ ____.
_______ ______ _________ ____ _______ ________ ________.
_______ ___ _______ ________ _______ _________.
__________ ________ _________ ___ ________ ________ _____ ____ _____ __________.
______ _________ __________ ______ _____ _______ _________.
_________ __________ ________ ____ ____ __________ ____ ____ __________ ________.
_______ ___ ___ _____ ______ ____ _________ ________ ____.
______ _________ _____ _________ _______ ________ ____ _________ _____ ___.
___ _________ _______ _________ _________ ____ _____ _______ ______ _________ ______.
__________ _____ ___ _________ ________ _____.
________ ___ ____ _________ ____ ________ _________ _________ _____ ______ ________.
___ _________ _____ __________ _______ ______ ________ __________ ________ _____ ____.
_____ ___ _______ __________ _______ ___ ______ _______ __________.
_____ ________ ______ ________ _______ _________ ______ __________ ______ ___ _________ __________.
_____ _____ ______ _______ ____ ___.
___ ___ ___ ______ _____ __________ __________ ________ ____.
______ ___ _________ ________ _____ ______ _______ ____.
_________ _______ _____ _____ ___ ________ _____ ________ _________.
____ ____ _________ ___ ___ ________.
_________ _____ ______ __________ ____.
_____ ___ ________ ____ ____.
___ __________ _____ _________ ____.
_____ _______ _____ ____ _____ ________.
_____ _________ ___ ___ ______ _____ _________ _______.
______ _________ _____ _____ _________ ___ ________ ____ ____ ____ ____.
____ _________ ________ _______ _______ ________ _______ ________.
________ ______ _________ _______ ____ _________ ________ ____.
__________ _________ ________ ___ ________ ________ _______.
_____ ________ ________ _______ _________ ___ __________ ____ ___ _____.
________ ________ ____ _________ __________.
________ ____ ________ _________ __________ __________ _________ ___.
_________ ______ ___ _______ _________ ____ __________ ________ _____.
_______ ___ __________ ___ ____.
_________ _______ ________ ____ ___.
______ ___ _______ ______ ____ ____ __________ ________ ________ _________ ________ ____.
_________ _________ _________ _________ ____ ______ __________.
______ ______ ________ _____ ___ __________ __________ ______ ____.
____ ________ ________ _________ _______ _________ _____ ________ ___ _______.
_____ ____ ____ __________ _________.
Get Full Answer on WhatsApp

IGNOU NEWS
Assignment Submission Last Date Extended Till 30 June 2026 Click Here★★★IGNOU June 2026 TEE Date Sheet Released Click Here★★★
Top
📞
Call Support Instant phone assistance Write a NEAR subroutine using 8086 assembly Language (with proper comm
🟢
WhatsApp Chat Fast live messaging
Email Us Business enquiries & support