0

Constructor = ethod

What is the difference between constructor and method? Auf Deutsch wird die Antwort viel besser :D

15th Jan 2020, 5:57 PM
Васил Раев
Васил Раев - avatar
5 Antworten
+ 7
Constructor is spacial method that will be invoked at the time of object creation.
15th Jan 2020, 6:59 PM
Sumit Programmer😎😎
Sumit Programmer😎😎 - avatar
+ 2
Constructor is a special method that only serves to initially set up a new instance. Methods are everything else, everything the instance 'does'.
15th Jan 2020, 6:38 PM
HonFu
HonFu - avatar
+ 1
Constructor can't return a value.
15th Jan 2020, 6:02 PM
Seb TheS
Seb TheS - avatar
+ 1
Thank youu :)
15th Jan 2020, 7:01 PM
Васил Раев
Васил Раев - avatar