CNIT 155 EXAM 1 QUESTIONS & ANSWERS
T/F: C# is more popular that Java in software development market. - Answers -False
What does IDE stand for?
A. Integrated Development Elements
B. Initial Design Elements
C. Integrated Development Environment - Answers -C. Integrated Development
Environment
T/F: Object instantiation is the creation of an object from a class. - Answers -True
What is inheritance in OOP?
A. A class can be derived from another class inheriting the properties and methods of
the parent class.
B. Inheritance is one of the main features of OOP.
C. Both A and B - Answers -C. Both A and B
Which namespace is at the top of the namespace hierarchy in VS.NET?
A. Forms
B. Windows
C. System - Answers -C. System
In object oriented programming, a class is a [x] that describes an [y]. - Answers -x =
blueprint
y = object
What is encapsulation?
A. Means having the properties and behavior of an object all in one place.
B. Is one of the cornerstones of OOP.
C. It aids in hiding data (property) in an object.
D. all of the above - Answers -D. all of the above
T/F: The behaviors of an object are called methods. - Answers -True
What is a namespace?
A. It is the name of a space.
B. It is a collection of class definitions.
C. It is the .NET framework class library.
, D. It is a class. - Answers -B. It is a collection of class definitions.
In object oriented programming, state of an object is:
A. the behavior of the object.
B. All the properties and methods of the object.
C. All the values assigned to the properties of the object. - Answers -C. All the values
assigned to the properties of the object.
To access the property of an object use ________.
A. ; operator
B. = operator
C. dot operator . - Answers -C. dot operator .
What will be store in variable m and n by the following?
int m, n;
n = 11;
m = 10;
m *= n + 1;
A. 111, 11
B. 120, 11
C. 12, 12
D. 110, 11 - Answers -B. 120, 11
What will be stored in a and b by the following statements?
int a, b;
a = 12;
b = 15;
b = --a;
A. 11, 12
B. 11, 15
C. 12, 11
D. 11, 11 - Answers -D. 11, 11
What is Pow in the following ?
double result;
result = Math.Pow (17, 5); - Answers -method
Evaluate the following expression:
T/F: C# is more popular that Java in software development market. - Answers -False
What does IDE stand for?
A. Integrated Development Elements
B. Initial Design Elements
C. Integrated Development Environment - Answers -C. Integrated Development
Environment
T/F: Object instantiation is the creation of an object from a class. - Answers -True
What is inheritance in OOP?
A. A class can be derived from another class inheriting the properties and methods of
the parent class.
B. Inheritance is one of the main features of OOP.
C. Both A and B - Answers -C. Both A and B
Which namespace is at the top of the namespace hierarchy in VS.NET?
A. Forms
B. Windows
C. System - Answers -C. System
In object oriented programming, a class is a [x] that describes an [y]. - Answers -x =
blueprint
y = object
What is encapsulation?
A. Means having the properties and behavior of an object all in one place.
B. Is one of the cornerstones of OOP.
C. It aids in hiding data (property) in an object.
D. all of the above - Answers -D. all of the above
T/F: The behaviors of an object are called methods. - Answers -True
What is a namespace?
A. It is the name of a space.
B. It is a collection of class definitions.
C. It is the .NET framework class library.
, D. It is a class. - Answers -B. It is a collection of class definitions.
In object oriented programming, state of an object is:
A. the behavior of the object.
B. All the properties and methods of the object.
C. All the values assigned to the properties of the object. - Answers -C. All the values
assigned to the properties of the object.
To access the property of an object use ________.
A. ; operator
B. = operator
C. dot operator . - Answers -C. dot operator .
What will be store in variable m and n by the following?
int m, n;
n = 11;
m = 10;
m *= n + 1;
A. 111, 11
B. 120, 11
C. 12, 12
D. 110, 11 - Answers -B. 120, 11
What will be stored in a and b by the following statements?
int a, b;
a = 12;
b = 15;
b = --a;
A. 11, 12
B. 11, 15
C. 12, 11
D. 11, 11 - Answers -D. 11, 11
What is Pow in the following ?
double result;
result = Math.Pow (17, 5); - Answers -method
Evaluate the following expression: