Visvesvaraya Technological University (VTU) 2008-2nd Sem B.E Electronics
Wednesday, 12 June 2013 11:00Web
Page 2 of 2
b. List out rules to be followed for defining variable. provide 1
example for every rule with invalid case. (08 Marks)
c. Write program to obtain the greatest of three numbers using conditional
Operator. (06 Marks)
5 a. Write a note on :
i) Break statement ii) continue on statement (04 Marks)
b. Write a program to obtain the roots of a quadratic formula using
Switch statement. (10 Marks)
c. elaborate the verities of if statement? discuss any two.(06 Marks)
6 a. Differentiate ranging from while and do-while statement. (05 Marks)
b. Using do-while, write a program to generate N prime numbers.
(10 Marks)
c. With general syntax discuss any 3 forms of for statement.
(05 Marks)
7 a. With an example discuss how the elements of 2 dimensional
array is stored in row major and column major order, if the base
address is 4000 and size of integer is two bytes.
(05 Marks)
b. Write a program to sort the elements of an array in ascending
order by selection sort.
(10 Marks)
c. elaborate the advantages and disadvantages of binary search?
(05 Marks)
8 a. What is a function? elaborate its advantages? (05 Marks)
b. elaborate the various ways of passing parameters to the
functions? discuss.
(05 Marks)
c. Write functions to perform the following:
i) To obtain the length of the string
ii) To check whether the string is palindrome or not. (10 Marks)
*****************
Earning: Approval pending. |