Menu mobile
Home
Programming
Python Tutorial
Java Tutorial
C Tutorial
C++ Tutorial
Web Technology
HTML
CSS
Java Script
PHP
React JS
Node JS
Assignment
MS Office
HTML
CSS
Bootstrap
Java Script
JQuery
AngularJs
Project
Blog
QUIZ ON : java - JAVA CONSTRUCTORS
JAVA CONSTRUCTORS
00:00:00
English
Hindi
Question No# :
01
out of 8
return type of Constructors function is
कंस्ट्रक्टर्स फ़ंक्शन का रिटर्न प्रकार है
A.
Void
Void
B.
Int
Int
C.
Array
Array
D.
Constructor function no return any value
Constructor function no return any value
Question No# :
02
out of 8
What is true about a Constructor
एक कंस्ट्रक्टर के बारे में क्या सच है?
A.
Its name is plural of class name
Its name is plural of class name
B.
Its name has * symbol before it
Its name has * symbol before it
C.
Its name is same as of class name
Its name is same as of class name
D.
Its name has # symbol before it
Its name has # symbol before it
Question No# :
03
out of 8
Which of the following is not applicable for a constructor function?
Which of the following is not applicable for a constructor function?
A.
It has the same name as the class.
It has the same name as the class.
B.
It has no return-type
It has no return-type
C.
It is usually used for initialisation
It is usually used for initialisation
D.
It can be invoked using an object like any other member function
It can be invoked using an object like any other member function
Question No# :
04
out of 8
Which among the following is a type of constructor?
Which among the following is a type of constructor?
A.
Parameterised constructor
Parameterised constructor
B.
Non-parameterised constructor
Non-parameterised constructor
C.
Both a and b
Both a and b
D.
None of these
None of these
Question No# :
05
out of 8
Name the type of constructor that gets invoked when an object is created, which is initialised with the content of another object.
Name the type of constructor that gets invoked when an object is created, which is initialised with the content of another object.
A.
Copy constructor
Copy constructor
B.
Default constructor
Default constructor
C.
Overloaded constructor
Overloaded constructor
D.
None of these
None of these
Question No# :
06
out of 8
What access specifier for a constructor allows you to create an object only within the class?
What access specifier for a constructor allows you to create an object only within the class?
A.
public
public
B.
private
private
C.
protected
protected
D.
default
default
Question No# :
07
out of 8
If the name of a class is ‘Number’, what can be the possible name for its constructor?
If the name of a class is ‘Number’, what can be the possible name for its constructor?
A.
Number
Number
B.
number
number
C.
construct
construct
D.
Number_contruct
Number_contruct
Question No# :
08
out of 8
If constructors are overloaded, what differentiates it?
If constructors are overloaded, what differentiates it?
A.
Parameter list
Parameter list
B.
Return type
Return type
C.
Both a and b
Both a and b
D.
None of these
None of these
Latest Current Affairs 2024
Online Exam Quiz for One day Exam
Online Typing Test
CCC Online Test 2024
Python Programming Tutorials
Best Computer Training Institute in Prayagraj (Allahabad)
Best Java Training Institute in Prayagraj (Allahabad)
Best Python Training Institute in Prayagraj (Allahabad)
O Level Online Test in Hindi
Bank SSC Railway TET UPTET Question Bank
career counselling in allahabad
Sarkari Naukari Notification
Best Website and Software Company in Allahabad
Sarkari Exam Quiz