Sololearn: Learn to Code
New course! Every coder should learn Generative AI!
Try a free lesson
+ 6
An else if statement is only called if the last statement was false. Since the first statement is true, it will ignore all else/else if statements. If you remove the else, your code should work
5th Apr 2020, 3:08 AM
Jax
Jax - avatar
+ 2
Hay bro use Curley bracket to enclose {System.out.printIn("hello");} In both
5th Apr 2020, 3:08 AM
Ayush Kumar
Ayush Kumar - avatar