Modifier use within the viod main()
Dear forumers...
I am new to java and just trying out basic programs. I have just learnt about the access modifiers....... but as soon as I tried to use them in the void main() I got an error saying that the modifier public/private is not allowed here !!
Could anyone kindly explain to me why.... ?
------------------------------------------------------
public static void main()
{
....
private int x ....
}
error: modifier private not allowed here.
--------------------------------------------------------------
Much appreciated.
Ibn Aziz
|