Выводит две 6, но ругается, что делать?
package com.javarush.task.pro.task03.task0305;
import java.util.Scanner;
/*
Три числа
*/
public class Solution {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = sc.nextInt();
boolean t = (a == b); // false 4!=6
boolean t2 = (c == b); //true 6==6
if (t == t2) {
System.out.println(a+ " " +b); // не верно
} else if (t != t2) {
System.out.println(b+ " " +c); // верно, выврд на экран
} else if (a == b && b == c) System.out.println(a+ " " +b+ " " +c); // не верно
}
}