Is class and method same?

Yes, It is allowed to define a method with the same name as that of a class . There is no compile-time or runtime error will occur.

Sizin İçin Seçtik  Are methods part of a class?

Leave a Reply

Your email address will not be published. Required fields are marked *