0
What is constructor...pls tell me shortly
2 Antworten
0
a non static block which is implicitly invoked while object creation. constructors are mainly used to initialize fields. The first statement of constructor is a super() calling statement.If a programmer doesn't define a constructor in the program, then JVM puts a default constructor ie. no-arg constructor. constructors can be overloaded. I Hope this helps.
0
thanks bro