Добрый день! Все работает, все выводиться, но 4-й пункт почему-то не засчитывается.
package com.javarush.task.pro.task03.task0306;
import java.util.Scanner;
/*
Треугольник
*/
public class Solution {
private static final String TRIANGLE_EXISTS = "треугольник существует";
private static final String TRIANGLE_NOT_EXISTS = "треугольник не существует";
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
int ab = a + c;
int bc = b + c;
int ac = a + c;
boolean abAndc = (ab > c);
boolean bcAnda = (bc > a);
boolean acAndb = (ac > b);
boolean isAll = (abAndc && bcAnda && acAndb);
if (isAll)
System.out.println(TRIANGLE_EXISTS);
else
System.out.println(TRIANGLE_NOT_EXISTS);
}
}