Question 5
(a) Define programming language.
(b) Write the following mathematical expressions in BASIC notations:
(i) x(w + y)2;
(ii) ;
(iii) p = 2 (l + b).
(c) Write a simple BASIC program to calculate the area (A) of a rectangle with length (l) and breadth (b).
(d) List two levels of programming language.
The expected answers were:
5. (a) Programming language is an artificial language designed to communicate instructions to a machine, particularly the computer.
(b)(i) x * (w+y)^2 or x*(w+y)**2
(ii)
(iii) p = 2 *(l+b)
(c) BASIC PROGRAM TO CALCULATE AREA OF A RECTANGLE
10 REM “PROGRAM TO CALCULATE THE AREA OF A RECTANGLE”
20 INPUT “LENGTH” ; L
30 INPUT “BREADTH” ; B
40 LET A = L*B
50 PRINT “AREA =’’ ; A
60 END
OR
10 REM “PROGRAM TO CALCULATE THE AREA OF A RECTANGLE”
20 INPUT L
30 INPUT B
40 LET A = L*B
50 PRINT A
60 END
(d) Any two programming languages
Machine language;
Low-level language/ Assembly language;
High-level language.
The question was on Developing Problem-Solving Skills. The question was unpopular with the candidates. As reported, most candidates could not correctly answer this problem-solving skills question. It was majorly attributed to inadequate tutorship.
The performance was reported poor.
of it. The performance of candidates was reported to be average. |