A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

Important Notice!

Dear users, compscibits.com is now permanently moved to compsciedu.com. Please update all your links and bookmarks accordingly. Soon, the site will be accessible through URL compsciedu.com only.

81. We ___________________ to an abstract class.
a. Can create pointers
b. Can create references
c. Can create pointers or references
d. Can’t create any reference, pointer or instance
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Can create pointers or references

82. Which among the following is an important use of abstract classes?
a. Header files
b. Class Libraries
c. Class definitions
d. Class inheritance
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).Class Libraries

83. Use of pointers or reference to an abstract class gives rise to which among the following feature?
a. Static Polymorphism
b. Runtime polymorphism
c. Compile time Polymorphism
d. Polymorphism within methods
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).Runtime polymorphism

84. The abstract classes in java can _________________
a. Implement constructors
b. Can’t implement constructor
c. Can implement only unimplemented methods
d. Can’t implement any type of constructor
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).Implement constructors

85. Abstract class can’t be final in java.
a. True
b. False
c. May be
d. Can't say
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).True

86. Can abstract classes have static methods (Java)?
a. Yes, always
b. Yes, but depends on code
c. No, never
d. No, static members can’t have different values
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).Yes, always

87. It is _________________________ to have an abstract method.
a. Not mandatory for an static class
b. Not mandatory for a derived class
c. Not mandatory for an abstract class
d. Not mandatory for parent class
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Not mandatory for an abstract class

88. How many abstract classes can a single program contain?
a. At most 1
b. At least 1
c. At most 127
d. As many as required
View Answer Report Discuss Too Difficult! Search Google
Answer: (d).As many as required

89. Is it necessary that all the abstract methods must be defined from an abstract class?
a. Yes, depending on code
b. Yes, always
c. No, never
d. No, if function is not used, no definition is required
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).Yes, always

90. A template class can have _____________
a. More than one generic data type
b. Only one generic data type
c. At most two data types
d. Only generic type of integers and not characters
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).More than one generic data type