CCC '14 J1 - Triangle Times
Source Code
import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int a = in.nextInt();
int b = in.nextInt();
int c = in.nextInt();
if(a + b + c != 180){
System.out.println("Error");
}else if(a == b && c == b){
System.out.println("Equilateral");
}
else if(a == b || a == c || c == b){
System.out.println("Isosceles");
}else if(a != b && c != b){
System.out.println("Scalene");
}
}
}