It seems that my code is OK (tried different versions), but still giving me errors. Any help will be appreciated! :)
package com.codegym.task.task04.task0415;
/*
Rule of the triangle
*/
import java.io.*;
import java.util.Scanner;
public class Solution {
public static void main(String[] args) throws Exception {
//write your code here
Scanner sc = new Scanner(System.in);
System.out.println("A: ");
int a = sc.nextInt();
System.out.println("B: ");
int b = sc.nextInt();
System.out.println("C: ");
int c = sc.nextInt();
if((a + b) > c || (a + c) > b || (b + c) > a){
System.out.println("The triangle is possible.");
}
else if(c >= (a + b) || b >= (a + c) || a >= (b + c)){
System.out.println("The triangle is not possible.");
}
}
}