18csc202j Oodp Ct1 Question-Old
18csc202j Oodp Ct1 Question-Old
18csc202j Oodp Ct1 Question-Old
Cycle Test – I
Academic Year: Aug-Dec 2020
2. The input and output operations involve the transfer of bytes known to be
a) Streams
b) Pointers
c) Objects
d) Class
3. The value of a data type when converted into the another data type is known
to be
a) Polymorphism
b) Class
c) Casting
d) Data reusable
5. The function which supersedes the data hiding feature in Object Oriented
Programming is
a) Static function
b) Friend function
c) Constant variable
d) Constructor
7. The design perspective of Object Oriented concepts for the structural and
behavioral aspect lays the diagrams of
a) Use case diagram and object diagram
b) Use case diagram and class diagram
c) Class diagram and object diagram
d) Class diagram, object diagram and usecase diagram
8. The notation in UML diagram that combines related classes of objects into a
distinct, more general class
a) Association
b) Composition
c) Generalization
d) Multiplicity
14.
The following program fragment
void main ( )
{
int v=10;
int &a=v;
cout << &a << &v;
}
a) Prints 10 and address of v
b) Prints address of a and 10
c) Prints address of a or v twice
d) Compilation error
16. The notations that can be used in Use Case diagram are
i) describing the portion of action/function which is common across more than
one use case, ii) adding more functions to the existing use case, iii) scope of the
system iv) actions of the system
a) include,extend,usecase,system boundary
b) extend,include,system boundary,usecase
c) include,extend, system boundary,usecase
d) extend, include, usecse, system boundary
20. The result obtained in the fragment of the following program
int a=10;
static int b=5;
int main()
{
{
b=b+a;
int c=10;
a=b+a;
}
cout<<b<<”\t”;
cout<<c;
return 0;
}
a) 15 10
b) 15 0
c) Compiler error
d) 5 10
21. To produce the result as true insert the code to the fragment of the following
program
int a = 5;
int b = 5;
string c ="hello";
string d ="Hello";
if( // insert the code )
cout<<"true";
else
cout<<"false";
22. State the appropriate class code for the following program
class ABC
{
int a,b,c;
public:
ABC();
ABC(int ,int ,int );
};
// insert code here