y cant i declare method like public final static show()
Answers were Sorted based on User's Feedback
Answer / karthi
Return type of the method is missing
ex:
public final static void show(){}
now it ll work.
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / raghavendra singh
every method declaration must has one return type(even void)
just before their method name.without return type method has
no meaning.so add some return type also here.
that's why i can't declare method like public final static
show()
| Is This Answer Correct ? | 1 Yes | 0 No |
What is an Exception ?
Can java cast null?
Difference between final and effectively final ?
What is annotation in java?
What is unicode?
What are wrapped classes in java programming?
What is singleton class and how can we make a class singleton?
This is related to threads. I have a class with synchronized method m1(). Can I create different instances of this class and execute the m1() for different threads?
what is the full form of java
Hi Friends, can you explain instance in java. In general instance means "occurence of something" . In java what is instance.
JVM responsibility?
Why Static variable required in java?For ex,class A { static int a; int b; } Why static is required?