Vous êtes sur la page 1sur 1

Assignment 2

1. Write an 8086 Assembly Language calculator program that has all Math
functions, as well as the basic operators +, -, *, /, and % for two 16-bits sign
numbers.

2. Write an 8086 Assembly Language program to find out a given substring present
or not in a string (which would be taken from keyboard). Find out the position of
first occurrence of the substring and display the appropriate message.

3. Write an 8086 Assembly Language Program that accepts two sentences. The
program will find the common words those are present in both the sentences. For
example:
1st Sentence: “High above the city, on a tall column, stood the statue of the Happy Prince.”
2nd Sentence: “One night there flew over the city a little Swallow.”
Output:
Common Word(s): the, a, city

4. Write an 8086 Assembly Language Program to perform merge sort on a ten 16-
bits number array.

5. Write an 8086 Assembly Language Program to calculate the GCD of 3 unsigned


16-bit numbers.

6. Assume that two variables x and y are declared as double words and are used to
store unsigned hex integers. Write a program to add X and Y and display the
sum. The sum has to be stored in five bytes which may be named as “SUM”.

7. Write an 8086 Assembly Language Program to calculate the following series for a
given 8-bits number n: 1! - 2! + 3! – 4! + … (+/-) n!

8. Write a procedure to convert an 8-bit binary number to BCD number and vice-
versa without using DAA.

9. Write an 8086 alp to search a given 16-bit value using binary search in an array
of 16-bit numbers, which are in ascending order. Message should be displayed
indicating whether the search was a failure or a success. If it is a success case,
the position of the element in the array is to be displayed.

10. Write an 8086 alp to display the command line parameters, and the total length
of the parameters using DOS interrupts.

11. Write an 8086 alp to get the screen width (no of cols) using BIOS interrupt, and
calculate the no of rows from the appropriate word location in BIOS data area,
and clear the screen using BIOS interrupt.

12. Write an 8086 alp to read a string of 8 characters on screen at(x1, y1) and display
the same at (x2, y2) using BIOS interrupts. x1, y1, x2, y2 will be user input.

Vous aimerez peut-être aussi