BSD 1308 – ASSEMBLY LANGUAGE PROGRAMMING KCA Past Paper

UNIVERSITY EXAMINATIONS: 2019/2020
EXAMINATION FOR DEGREE OF BACHELOR OF SCIENCE IN SOFTWARE
DEVELOPMENT
BSD 1308: ASSEMBLY PROGRAMMING
MODE: FULL TIME/PART TIME/DISTANCE LEARNING
ORDINARY EXAMINATIONS
DATE: MAY, 2020 DURATION: 6 HOURS
INSTRUCTIONS: Answer ALL Questions
SECTION II: 20 MARKS – PRACTICAL QUESTIONS

QUESTION ONE
a) Briefly explain the general format of an assembly program. 4 Marks
b) Write a simple assembly language program to multiply two real numbers 3.72 and 1.78 and
display the answer in four decimal places. 8 Marks
c) Write an assembly program to read length and width of a rectangle then calculate and display
the area. 8 Marks
SECTION III: 20 MARKS – APPLICATION QUESTION
QUESTION ONE
A painter wishes to buy some paint to paint a circular surface. There are two types of paints that
must be mixed in equal proportions to painter the surface. Painter A costs Ksh 1500 per liter while
paint B costs Ksh 3000 a liter. The paint consumption is 2 liters per every square meter of the
surface. Write an assembly program that uses procedures to calculate the cost of painting a circular
surface. One of the procedure should be able to read the radius of the circular surface then calculate
the area in square meters. Another procedure should calculate the total cost of painting once it
receives the area of the surface. 20 Marks

(Visited 211 times, 1 visits today)
Share this:

Written by