Why I am getting compile time error as 'else' without 'if'. Can anyone explain me with detail
class Test
{
public static void main(String[] args)
{
if(false)
if(true)
if(false)
else
System.out.println("1");
else
System.out.println("2");
else
System.out.println("3");
}
}
Aucun commentaire:
Enregistrer un commentaire