can we write program without class

Answer Posted / mahipal

no,because java is purely object oriented language,so we can't create the objects with out writing a class.And also we can save the code as classname.java that's the reason also we must create a class

Is This Answer Correct ?    3 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we define private and protected modifiers for the members in interfaces?

832


How many types of memory areas are allocated by jvm?

772


What is public static?

744


What is the difference between a method and a procedure?

760


When is update method called?

886


Difference between string, string builder, and string buffer?

747


When will we use them?

810


What is java util hashmap?

732


Explain java coding standards for variables ?

881


What is foreach loop in java?

756


What will happen if a thrown exception is not handled?

753


What is the point of java?

778


What is java used for on a computer?

721


Can a main method be declared final?

801


What is the purpose of using java.lang.class class?

751