Documente Academic
Documente Profesional
Documente Cultură
1
5. a) What do you mean by Stack Versus heap? Explain about memory 8
recovery. Explain the use of new and delete operator.
b) What will be the order of constructor invocation for the following 7
code snippet:
Class Date {
.
….
};
Class Time {
………
……….
};
Class Bus }
int bus () ;
Date dep- date ;
Time dep-time;
…..
……
};
int main ( )
{
Date D1 ;
Time T1 ;
Bus bs 1
….
….
}
6. a) Write a program to convert polar coordinate system to rectangular 7
coordinate system. Write the conversion function in source class.
b) Create an abstract base class shape with two members base and 8
height, a member function for initialization and a pure virtual
function to compute area ( ). Derive two specific classes Triangle
and Rectangle which override the function area ( ). Use these
classes in a main function and display the area of a triangle and a
rectangle.
7. Write short notes on (Any Two): 2x5
a) Non linear Behaviour of Complexity
b) Exeption Handling
c) Cohesion and coupling