What is the difference between a main method and a method contained in a class?

Every method has to be part of a Class. The difference between a main method (actually the main method which you are talking about) and any other method is that execution of the program starts at the main method . A method represents a functionality or a set of instructions that have been grouped together.

Sizin İçin Seçtik  What is the relationship between base class and subclass?

Leave a Reply

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

What is the difference between a main method and a method contained in a class?

Every method has to be part of a Class. The difference between a main method (actually the main method which you are talking about) and any other method is that execution of the program starts at the main method . A method represents a functionality or a set of instructions that have been grouped together.

Sizin İçin Seçtik  What are objects and classes explain with an example?

Leave a Reply

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