Programing Assignment
Programing Assignment
1. Develop an assembly language program for adding n number of words. Demonstrate the role
of Assembler Directives in this example. Assume data block starts from address DATA.
LENGTH indicates address where length of the data block is stored. Also store the sum from
location SUM.
2 Develop an assembly language program for adding n number of words. Assume data block
starts from address DATA, LENGTH indicates address where length of the data block is
stored. Store sum from location SUM.
3 Assume that the list of scores of n students are stored as shown in the following figure.
Develop a program to add Test 1 marks, Test 2 marks and Test 3 marks of all students and
store them in address SUM1, SUM2 and SUM3 respectively.
4 Develop a program for addition of n numbers using the concept of parameters passing
through registers. Assume N is the address of n, 32-bit data words, NUM1 is the address of
first data word. Consider N and NUM1 as parameters to be passed from calling program to
called program.
5 Let A and B be two vectors of length n. Their dot product is defined as