0
How do I solve this illegal start of expression error😭
2 ответов
+ 1
Remove semicolons from if cases and also take care of parentheses
import java.util.*;
class UserInputDemo
{
public static void main(String[] args)
{
Scanner sc = new Scanner (System.in);
int a,b,c;
a=sc.nextInt();
b=sc.nextInt();
c=sc.nextInt();
if (a+b+c==180)
{
if ((a==90||b==90||c==90)&&(a==b||b==c||a==c))
{
System.out.println("ISOSCELES RIGHT∆");
}
if(a==90||b==90||c==90)
System.out.println("Right ∆");
}
}
}
+ 2
Check in line 13:
* ==, not =
* count the number of parentheses: There are unmatched parentheses in the expression