Hi..
I am new to java and need a help on this part
I am declaring a variable as below and it is showing error.. as identifier required.. help me out to understand the reason behind the same..
class abc
{
int a;
a=10; // on this point it is asking for identifier reuired
public static void main(String[] args)
System.out.println(a);
}
as i have already declared int a, why cant i assign a=10 in the next statement
Response ASAP .... appreciated..
Thanks in advance
Sorry if i have posted it in wrong category but the thg is i need a immediate help and am quit weired out