Answer Posted / susheel kumar
A constructor is a special type of member function for
automatic initialization of an object.
when ever an object is created the constructor will be
executed automatically.
the name of constructor same as that of its class.the
constructor is declared with no return type,not even void.
constructor should be declared in the public section most
of the time.
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
How do you disable javascript?
Why do we need hoisting in javascript?
Is javascript array dynamic?
How many days it will take to learn javascript?
What are the different objects used in javascripts?
Can you give an example showing javascript hoisting?
What is data type in javascript?
What is the statement to enable strict mode in javascript quiz?
How do you access an element in an HTML document with JavaScript?
what is a dataset
How do I retrieve a cookie with a given name using a regular expression?
How to manage exception handling in javascript?
What is scope variable in javascript?
How do you check if a string is a number javascript?
What are parameters in javascript?