본문 바로가기

휴지통665

백준 20300 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; import java.util.StringTokenizer; class Main20300 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); long[] t = new long[N]; StringTokenizer st = new StringTokenizer(br.readLine()); fo.. 2023. 7. 18.
백준 20115 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; import java.util.StringTokenizer; class Main20115 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); int[] x = new int[N]; StringTokenizer st = new StringTokenizer(br.readLine()); for .. 2023. 7. 18.
백준 11047 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.StringTokenizer; class Main11047 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine()); int N = Integer.parseInt(st.nextToken()); int K = Integer.parseInt(st.nextToken()); int[] A .. 2023. 7. 15.
백준 11399 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; import java.util.StringTokenizer; class Main11399 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); int[] P = new int[N]; StringTokenizer st = new StringTokenizer(br.readLine()); for .. 2023. 7. 15.
백준 11508 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; class Main11508 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); List C = new ArrayList(N); for (int i = 0; i < N; i++) { C.ad.. 2023. 7. 15.
백준 1758 import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; class Main1758 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); int[] tip = new int[N]; //원래 주려고 했던 돈 - (받은 등수 -1) 만큼의 팁을 준다. for (int i = 0; i < N; i++) { tip[i] = Integer.parseInt(.. 2023. 7. 14.