Write an assembly program to find out largest number, Assembly Language

Assignment Help:

Program :  Write an assembly program to find out the largest number from a given unordered array of 8-bit numbers that stored in the locations starting from a known address.

Solution :

Compare the number of the series with the (i+1 )th number by using CMP instruction. It will set the flags suitably, depending upon whether the ith number or the (i+1 )th number is higher. If the ith number is higher than (i+1 )th, leave it in register AX (any register can be used ). Or else, load the (i+1 )th number in register AX, replacing  the ith number  in AX. The process is repeated till all the members in the array have been compared.

1547_program2.jpg


Related Discussions:- Write an assembly program to find out largest number

Write an assembly program to design an array, 1- Write an assembly program ...

1- Write an assembly program that:   a- Defines an array of 10 (word type)elements;   b- Finds out the number of negative elements   c- Calculate the summation of the posi

8086 assembly language program, move a byte string ,16 bytes long from the ...

move a byte string ,16 bytes long from the offset 0200H to 0300H in the segment 7000H

Program, write a program assembly language for adding two 3*3 matrix

write a program assembly language for adding two 3*3 matrix

Das-arithmetic instruction-microprocessor, DAS: Decimal Adjust after Subtr...

DAS: Decimal Adjust after Subtraction:- This instruction converts the result of subtraction operation of 2 packed BCD numbers to a valid BCD number. The subtraction operation has

Icwi-microprocessor, The definitions of the bits in ICWI are following: ...

The definitions of the bits in ICWI are following: Always set to the value 1. It directs the received byte to ICWI as oppose to OCW2 or OCW3. Which also utilize the even addr

Summation Program., Write a program to solve problem 9, Summation Program, ...

Write a program to solve problem 9, Summation Program, on page 179 of chapter 5 in the textbook (book:kip Irvine Assembly Language sixth edition)

Debug-microprocessor, Using DEBUG DEBUG.COM is a DOS efficacy that faci...

Using DEBUG DEBUG.COM is a DOS efficacy that facilitates the trouble-shooting and debugging of assembly language programs. In particular case of personal computers, all of th

Bcsl-022, define accounting.briefly explain the accounting concepts which g...

define accounting.briefly explain the accounting concepts which guide the accountant at the recording stage.

Movsw/movsb-string manipulation instruction-microprocessor, MOVSW/MOVSB : ...

MOVSW/MOVSB : Move String Word or String Byte: Imagine a string of bytes, stored in a set  of consecutive memory locations is to be moved to another set of  the destination locati

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd