package com.codegym.task.task04.task0420;
/*
Sorting three numbers
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader (new InputStreamReader(System.in));
String alpha = reader.readLine();
int a = Integer.parseInt(alpha);
String beta = reader.readLine();
int b = Integer.parseInt(beta);
String ceta = reader.readLine();
int c = Integer.parseInt(ceta);
int[] numbers = {a, b, c};
Arrays.sort(numbers);
System.out.println (numbers[0] +" "+ numbers[1] +" "+ numbers[2]);
}
}
What am i doing wrong?package com.codegym.task.task04.task0420;
/*
Sorting three numbers
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader (new InputStreamReader(System.in));
String alpha = reader.readLine();
int a = Integer.parseInt(alpha);
String beta = reader.readLine();
int b = Integer.parseInt(beta);
String ceta = reader.readLine();
int c = Integer.parseInt(ceta);
int[] numbers = {a, b, c};
Arrays.sort(numbers);
System.out.println (numbers[0] +" "+ numbers[1] +" "+ numbers[2]);
}
}