Я не понимаю, пробовал посидеть посмотреть работу других, пробовал разными методами, не выходит, помогите пожалуйста.
package com.javarush.task.task04.task0420;
import java.io.BufferedReader;
import java.io.InputStreamReader;
/*
Сортировка трех чисел
*/
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
int a, b, c, num1, num2, num3;
a = Integer.parseInt(reader.readLine());
b = Integer.parseInt(reader.readLine());
c = Integer.parseInt(reader.readLine());
num1 = a;
num2 = b;
num3 = c;
int x, y, z;
x=Math.min(Math.min(a, b), c);
z=Math.max(Math.max(a, b), c);
if ((x < a)&(a < z))
y = a;
else if ((x < b)&(b < z))
y = b;
else
y = c;
System.out.println(z + " " + y + " " + x);
}
}