this(1,2,3)
what it can ?
Resolved
Comments (5)
- Popular
- New
- Old
You must be signed in to leave a comment
Sharif Sharipov
20 February 2020, 15:03
Hi Raj,
You can use this key word in order to call constructor if you are in the same class. You can have multiple contractors in the same class as long as they are different in the number of arguments or type of arguments.
0
Abdul-Hamed Mohammed
20 February 2020, 05:38
Please attach your code, so we can give suggestions on solving a problem.
0
Ashish RajAnand
20 February 2020, 07:04
calling a constructor from a constructor
0
Abdul-Hamed Mohammed
20 February 2020, 08:05solution
If you just want to learn about calling a constructor from a constructor then follow this link it explains it well.
https://beginnersbook.com/2013/12/java-constructor-chaining-with-example/
+2
Ashish RajAnand
20 February 2020, 08:52
thanks
0