문제링크
https://www.acmicpc.net/problem/2750
package BOJ;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
public class Main_2750 {
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int N = Integer.parseInt(br.readLine());
int arr[] = new int[N];
for(int i=0;i<N;i++) arr[i] = Integer.parseInt(br.readLine());
Arrays.sort(arr);
for(int i=0;i<N;i++) System.out.println(arr[i]);
}
}
'알고리즘 > 백준' 카테고리의 다른 글
[JAVA]백준_2644_촌수계산 (0) | 2021.06.26 |
---|---|
[JAVA]백준_2583_영역구하기 (0) | 2021.06.26 |
[JAVA]백준_10773_제로 (0) | 2021.06.24 |
[JAVA] 백준_2468_안전영역 (0) | 2021.06.24 |
[JAVA]백준_10814_나이순정렬 (0) | 2021.06.23 |