Professional Documents
Culture Documents
Semester : VI
Duration : 3 hours
Maximum Marks : 75
1
1. Attempt all parts of the question.
(a) Write the full form of the following:
(i) ROM
(ii) BCD
(iii) CPU
(iv) www
(v) ALU
(c) State whether the following are valid or invalid variable names? Identify the error if
any:
(i) N$1
(ii) AB(1)
(iii) X-Y
(iv) NEW
(v) SUM
(6.25, 6.25, 6.25)
(b) Identify the error, if any, in the following constants and correct them.
(i) 51,284
(ii) 46.25
(iii) New “Delhi-110001”
(iv) 1.85×E−5
(v) “Computer”
(vi) $100.75
(c) Write a program in BASIC to separate the odd and even numbers from the following
list: 68, 45, 42, 97, 85, 33, 54.
(6, 6, 6.75)
3. (a) Explain the meaning of the following error messages:
(i) For without next
(ii) Division by zero
(iii) Subscript out of range
2
(b) Write the BASIC statements to get the following output:
(i) A line from top left corner to bottom right corner of the screen
(ii) An integer not greater than 4.6
(iii) Clear the output screen
(c) What are library functions? Write the use of the following functions. Give one example:
(i) SGN(X)
(ii) FIX(X)
(iii) SIN(X)
(iv) LOG (X)
(6, 6, 6.75)
(b) Write a program in BASIC to read the following data and get the output as a list
showing the names and their respective marks in the decreasing order of marks.
Marks 35 38 44 41 36 42
3
5.
(a) Identify and correct the errors in the following program:
(b) Identify the error in each step, if any, and write the correct program to calculate the
real roots.
(c) Write a user-friendly program in BASIC to plot a graph of a particle in 1-D box of
length 10 and quantum number, n = 2.
(6, 6, 6.75)
6 (a) Write a program in BASIC to print matrix C as a sum of the following two matrices
A and B:
1 2 3 3 2 1
A= 5 4 6 and B= 6 5 4
7 8 9 9 8 7
(b) Write short notes on the following:
(i) Newton Raphson’s method to determine the root of a polynomial equation.
(ii) Hierarchy of mathematical operations in BASIC
(c) How many graphic screens are available in BASIC? Which one of the screens has
higher resolution? Write the command to change from text screen to graphics screen.
4
How many rows and columns of pixels are present in all the graphics screens of
BASIC? Which of the following commands work only in graphic screen of QBASIC?
(i) VIEW (ii) WINDOW (iii) LOCATE (iv) CLS (v) PSET (vi) REM (vii) LINE
(6, 6, 6.75)