Question

Write and run an 8086-assembly language program that computes the multiplication of 5 natural numbers, starting from number 2. You should use the looping construct to write this program. The result is stored in a word memory location. Make and state suitable assumptions, if any

15 Sep 2022
Answer :
Word Count : 299

Code for the 8086 assembly language program to compute the multiplication of 5 natural numbers starting from 2:

; Program to find the multiplication of 5 natural numbers starting from 2

; Assumptions:
; 1. The program assumes that the numbers to be multiplied are all natural numbers.
; 2. The result is stored in a word memory location.

; Variables:
__________ ______ _____ ______ _____ _______ _____ _________ _____ _________.
______ _________ ___ _______ _________ _________.
______ ___ __________ ______ __________ ______ _________.
___ ____ _________ _________ ________ ________ ______ ______.
________ _______ __________ ________ ___ ____ _____ ______ ____ _________ __________ __________.
__________ ____ _________ _____ _______.
____ ___ _________ _____ _________ _____ _________ _________ ___ __________ ____.
__________ _______ __________ ______ __________ __________ _____ _______ __________ ____.
___ ____ ____ ____ _________ ____ ____ ____ ____ ___ _____.
________ ___ ________ ________ _______.
_______ ____ ____ ___ __________ _________ __________ __________.
________ _________ ________ _______ ________ _____.
___ ___ ____ ________ _________ ________ _____ ______ _______ __________ _________ _________.
_________ __________ ______ _______ _________.
___ ________ ________ _______ _______ ____ _______ ____.
____ ____ ______ _______ _____ ____ __________ ____ _______ ___.
______ ____ ___ ____ _____ ______ _________ ______ _____.
____ ________ _____ _________ ______ ___ _________.
____ _____ _______ __________ _______.
_____ ___ ___ _________ ______ ___ ___ _________ _________ _________.
___ ______ __________ ____ ____ _________ __________ ___ ________.
___ _____ ______ ________ __________ __________ ________ ________.
_______ _________ _______ _______ __________.
______ _____ ____ ______ _______ ____ _____ _________ ____ ___ ______.
____ _____ _______ _________ ____ ________ _______ ______ _____.
_____ ________ ____ __________ __________ ______ _____ _____.
______ __________ ______ ____ ___ ____ ___.
___ ______ ________ ________ _________ ________ ___ _______ _______ _______ ____ ________.
____ ____.

IGNOU ACADEMY
Your IGNOU journey, made easier.
  • Solved Assignments
  • Study Notes
  • Guess Papers
  • Question Papers
Skip in 10
'; fetch( "query.php?type=1&method=0&lr=0&app=401&mycartproduct=1", { method: "GET", cache: "no-store" } ) .then(function(response) { if (!response.ok) { throw new Error( "HTTP " + response.status ); } return response.text(); }) .then(function(html) { loader.innerHTML = html; /* Your existing function, if available. */ if (typeof updateTotals === "function") { updateTotals(); } else { calculateCartTotal(); } }) .catch(function(error) { console.error( "Cart loading error:", error ); loader.innerHTML = '
Unable to load cart.
'; });}/* ========================================================= CALCULATE TOTAL========================================================= */function calculateCartTotal() { let subtotal = 0; /* Looks for .item-price inside AJAX products. Examples accepted: ₹200 ₹200.00 Rs 200 Rs. 200 200 200.00 */ const prices = document.querySelectorAll( '#loadmycart .item-price' ); prices.forEach(function(element) { let text = element.textContent || ''; text = text .replace(/₹/g, '') .replace(/Rs\.?/gi, '') .replace(/,/g, '') .trim(); let value = parseFloat(text); if (!isNaN(value)) { subtotal += value; } }); updateCartDisplay(subtotal);}/* ========================================================= UPDATE TOTAL DISPLAY========================================================= */function updateCartDisplay(total) { const subtotalElement = document.getElementById('subtotal'); const totalElement = document.getElementById('total'); const checkoutButton = document.getElementById('checkoutButton'); const noItems = document.getElementById('noitems'); const amount = Number(total) || 0; if (subtotalElement) { subtotalElement.textContent = '₹' + amount.toFixed(2); } if (totalElement) { totalElement.textContent = '₹' + amount.toFixed(2); } /* EMPTY CART */ if (amount
Top