what is default constructor and parameterised constructor
with example?
Answer / tushar
Default constructor: this constructor is created by the compiler automatically whenever an object is created.User don't have to write default constructor every class has its default constructor
Parameterized constructor: this constructor is exclusively written by the coder to assign the initial value to an instance variable.By creating parameterized constructor you can overwrite the default constructor.
| Is This Answer Correct ? | 1 Yes | 0 No |
Explain exception chaining in java?
Is oracle charging for java?
What is the final field modifier?
What is finalize()? Is finalize() similar to a destructor?
Explain about method local inner classes or local inner classes in java?
How could Java classes direct program messages to the system console, but error messages, say to a file?
What are some characteristics of interference class?
What do you understand by weak reference?
How many JVMs can run on a single machine and what is the meaning of Just-In-Time (JIT) compiler?
what is mean by method signature?
What is "finally" keyword?
What is the difference between actual and formal parameters?