CS304 Final Paper 23 February 2013

Total Questions: 52

Total Marks: 80

Total MCQs: 40 (Each of 1 Mark)
Total Short Questions: 4 (Each of 2 Mark)
Total Short Questions: 4 (Each of 3 Mark)
Total Long Questions: 4 (Each of 5 Mark)

2 mark Questions:
1. Write down a list of four intangible objects?
2. Describe three properties necessary a container to implement generic algorithms.

3. Write three important features of virtual functions
Give the C++ code of template function to print the values of any type of array I int.this function will take 2 parameters one will be pointer and other will be will be size of array ?
3 mark Questions:
1. Describe the salint feature of abstract class (mrk3)
2. define composition and give its example with coding

3. define static and dynamic binding.

4. what is constructor?

5 mark Questions:
1. What is the difference (if any) between the two types of function declarations?
template function_declaration;
template function_declaration;
2. Give three advantages that Iterators provide over Cursors.
3. What are container requirements (5)
4. What is random iterator? What is its relation with vectors?

Another Paper:

Current paper of Cs304

Total 52 questions:

4 questions of 2 marks

4 questions of 3 marks

4 questions of 5 marks.

2 mark Questions:

1. Write three important features of virtual functions

2 Give the name of three operation that a cursor or iterate generally provide?

3. What do you know about function Template? Answer in two line.

4. What is a Virtual Destructor?

3 mark Questions:

1.define static and dynamic binding.


2. What are container requirements?

3. Sort data in the order in which compiler searches a function. Complete specialization, generic

template, Partial specialization, Ordinary function.

4. what is constructor?

5 mark Questions:

1. Describe problems with multiple inheritances?

2.Consider the code below,

template< typename T >

class T1 {


   T i;


   T j;


   T k;

   friend void Test();



This code has a template class T1 with three members i,j and k and a friend function Test(), you have to

describe which member/s of T1 will be available in function Test().

3. Give the c++ code of case sensitive comparison function of string class.