Hi all,
I'm just starting Java and have read some tutorials and reading also thinking in Java and I see it is a good language. I have a question though, what are MINIMUM requirement of ANY Java program for it to run?

Every Java program needs a class defined in the file. You can define more than one class in a file and atleast one class as public and its name should be that of the file. In that public class you define main() method with public static void which is the trigger point for the java interpreter.

In my openion each program must have a class.

katharnakh.

Every Java program needs a class defined in the file. You can define more than one class in a file and atleast one class as public and its name should be that of the file. In that public class you define main() method with public static void which is the trigger point for the java interpreter.

In my openion each program must have a class.

katharnakh.

Full and self expalanatory!
Thanks!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.