LOADING

Questions

C++ Functions

Q-1(b)

(b)  Answer Following:
1.  Explain Inline function.
2.  Explain function overloading.

(7)
(Winter - Dec -
2015)
Q-2(a)

(a) i)  Define a class named student with attributes like name, roll number, age etc.
Create two different objects of this class with different values of their attributes
in C++ program.
ii)  Define the following terms with respect to OO concepts:
association, generalization, event , transit ion

(7)
(Winter - Dec -
2015)
Q-2(b)

(b)  What  is  friend  function? Write a program  to  find out sum of  two private data
members  x  and  y  of  two  classes  A  and  B  using  a  common  friend  function.
Assume that the prototype for both the classes will be void sum (A, B); 

(7)
(Winter - Dec -
2015)
OR
ORQ-2(c)

Q2.Define a class complex with real and imaginary as two data member, add necessary constructors and member function to initialize and display data of class. Class should overload the + operator to add two complex objects and return the results. Invoke the statements like C3=C1+C2 in main ().

(7)
(Winter - Dec -
2015)
Q-3(a)

 
(a) Explain call by value, call by reference and call by address with example.

(7)
(Winter - Dec -
2015)

(a)  1) Explain Inline function with example.
2) Explain Default argument in function with example.

(Winter - Dec -
2015)
Q-3(b)

(b)  Explain Friend function with example.

(7)
(Winter - Dec -
2015)

(b)  Explain friend function with example.

(Winter - Dec -
2015)
Q-4(a)

(a)    Write a C++ program to find an average value of n integers stored in array. 

(7)
(Winter - Dec -
2015)

(a)    Write a C++ program to check that the given integer number is prime or not.

(Winter - Dec -
2015)
Q-5

B,Write a programm to swap two integers by creating swap function using call by refernace?

(7)
(Winter - Dec -
2015)
ORQ-5(5)

a.Draw data flow diagram for library manegment systeam.

(7)
(Winter - Dec -
2015)

b.Write a programm to add privet members variables of two clasees using friend function.

(Winter - Dec -
2015)
Q-5(a)

Q-5

A. Define class and draw classe model of windowing systeam?

 

(7)
(Winter - Dec -
2015)