can we write a program with out a class in core java?

Answer Posted / subrat

ya we can do it by using enum,but it is also a predefined class.

public subrat
{
subrat;
public static void main(String k[])
{
System.out.println("SUBRAT");
}
}

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is autoboxing in java?

618


How does list work in java?

514


Can we write a class without main method in java?

488


Can we pass a primitive type by reference in java? How

534


List the features of java programming language.

575






When do I need to use reflection feature in java?

629


what is anonymous class in java?

559


Describe what a thread-local variable is in java?

579


What do you mean by stream pipelining in java 8?

746


What do you mean by singleton class in java?

524


Is nan false?

541


What are different types of constants?

532


how can i use a nonsynchronized hashtable?

2119


Does substring start with 0?

562


How can we find the actual size of an object on the heap?

818