How many ways to declare main() method in java?

There are so many ways to declare main() method  or so many predefined signature to declare main() method in java which could be understand by JVM.


p=public 
s=static 
v=void 
m=main 

for JDK1.0 up to all above version.
1.psvm(String[] a) 
2.spvm(String[] a) 
3.psvm(String []a) 
4.psvm(String a[]) 
5.spvm(String []a) 
6.spvm(String a[])
for JDK1.5 up to above version(VAR-ARGS) 
1.psvm(String... a) 
2.psvm(String...a) 
3.psvm(String ...a) 

4.spvm(String... a) 
5.spvm(String...a) 
6.spvm(String ...a) 

Popular posts from this blog

10 basic Java interview questions with their answers

Internal working of JVM(Java Virtual Machine)

Introduction to java programming language