If an application has multiple classes in it, is it okay to have a main method in more than one class?

By drakula david in 22 Sep 2023 | 12:41 pm
drakula david

drakula david

Student
Posts: 128
Member since: 22 Sep 2023

If an application has multiple classes in it, is it okay to have a main method in more than one class?

22 Sep 2023 | 12:41 pm
0 Likes
divas goyal

divas goyal

Student
Posts: 453
Member since: 22 Sep 2023

 An application can have multiple classes with a `main` method, but only one of them is the entry point for executing the program. Each `main` method can be run independently.

23 Sep 2023 | 04:04 pm
0 Likes

Report

Please describe about the report short and clearly.