Get premium membership and access revision papers, questions with answers as well as video lessons.

Comp 212:Object Oriented Programming April 2009 Question Paper

Comp 212:Object Oriented Programming April 2009 

Course:Bachelor Of Education Science

Institution: Kabarak University question papers

Exam Year:2009



KABARAK UNIVERSITY EXAMINATIONS
2008/2009 ACADEMIC YEAR
FOR THE DEGREE OF BACHELOR OF EDUCATION
SCIENCE
COURSE CODE: COMP 212

INSTRUCTIONS:
Attempt QUESTION ONE and Any Other TWO

QUESTION ONE (30 marks)
a. Discuss any features of procedure programming [4 marks]
b. (i) What is a function? [2 marks]
(ii) Write a note on friendly functions [2marks]
c. Discuss memory allocation and de allocation technique available in c++ [4 marks]
d. Write a c++ program to find sum of a given non negative integer of n number where n
is entered by the user using function declaration [ 6 marks]
e. (i) Describe the constructor and destruction, [3 marks]
(ii) What are rules followed when they are declared. [3 marks]
f. (i) What is inheritance? [2 marks]
(ii) Discuss any four types of inheritance available in c++. [4 marks]

QUESTION TWO (20 marks)
a. Compare the differences in c++ and java [4 marks]
b. What is identifier? What are rules followed when declaring a identifier? [4 marks]
c. Write a c++ program to find factorial of given number [6 marks]
d. Write a program to find area of a triangle [6 marks]

QUESTION THREE (20 marks)
a. What is an array? What are rules used when declaring an array? [4 marks]
b. Discuss about enumerated data types with example [4 marks]
c. Using a suitable example describe a constant? [4 marks]
d. what is a function overloading? [2 marks]
e.(i) What is a pointer [ 2 marks]
(ii) Describe the advantages of using pointers [4 marks]

QUESTION FOUR: (20 marks)
a. Describe any three conditional statements [6 marks]
b. What is the use of conditional operator (?) [2 marks]
c. Briefly explain call by value and call by reference [4 marks]
d. Write a program to find odd and even numbers in the given array. [4 marks]
e. write a program to display name and age using a class [ 4 marks]

QUESTION FIVE (20 marks)
a. What is a class? Describe its structure [4 marks]
b. Using a suitable example describe inline function [ 4 marks]
c. Using switch statement write a c++ program to display the day depending ion the
choice entered by the user from the key board [ 6 marks]
d. Discuss six principles of object oriented programming [6 marks]






More Question Papers


Popular Exams


Mid Term Exams

End Term 1 Exams

End Term 3 Exams

Opener Exams

Full Set Exams



Return to Question Papers