Two major differences: One, constructors must have same name as the class and can’t have any return type. Two, constructors are called only once, while other methods can be called multiple times.
![]() |
Two major differences: One, constructors must have same name as the class and can’t have any return type. Two, constructors are called only once, while other methods can be called multiple times.
![]() |
No comments:
Post a Comment