Identification of triangles in Java – Battery overflow

I do java exercises, but I do not find logic for that:
Get 6 numbers representing the measures a, b, c, d, e and f to indicate how many and which triangles it is possible to form with these measurements (to form a triangle, the sum of the shorter sides must be greater than the measure on the longest side) Example output [abc], [abd]… I can do logic with 3 values ​​only

System.out.print ("Enter the first measure:");
int a = sc.nextInt ();
System.out.print ("Report the second measure:");
int b = sc.nextInt ();
System.out.print ("Enter the third measure:");
int c = sc.nextInt ();
System.out.print ("Report the fourth measure:");
int d = sc.nextInt ();
System.out.print ("Report the fifth measure:");
int e = sc.nextInt ();
System.out.print ("Report to sixth measure:");
int f = sc.nextInt ();

If (a + b> c) && (a + c> b) && (b + c> a)
if (a == b && a == c) {
System.out.println ("equilateral triangle.");
}
otherwise if ((a = b) || (a == c) || ​​(b == c)) {
System.out.println ("Triangle isosceles.");
}
if not {
System.out.println ("Scalene Triangle.");
}
System.out.println ("Measures used: [abc]");
}

if not {
System.out.println ("Do not form a triangle.");
}