Hello everyone, I just need help on this code. I can't debug it, I'm just new in Java and this is just my fifth assignment so I'm really having a hard time.
Here's my code:
import java.io.*;
public class input
{
public static InputStreamReader Reader=new
InputStreamReader (System.in);
public static BufferedReader input=new
BufferedReader(Reader);
public static void main(String args[]);
String name;
int age;
double salary;
{
System.out.println("Enter name:");
name=input.readline();
System.out.println("Enter age:");
age=Integer.parseInt(input.readLine());
if(age<=18)
System.out.println("Too young!");
}
else if (age>=18);
{
System.out.println("You're ready to vote!");
}
}
the Error says that:
illegal start of type line 20
<identifier> expected line 20
else if (age>=18);
Can anyone please tell me how to debug it? =/