본문 바로가기

알고리즘/일반(단순구현)10

[백준] 7568번 : 덩치 #Java import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.*; class Person{ int w,h,rank; Person(int weight,int height){ this.w = weight; this.h = height; } } public class Main { static int [][] dp = new int[15][15]; public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in.. 2022. 5. 7.
[백준] 2292번 벌집 #Java import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.*; public class Main { static int [][] dp = new int[15][15]; public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int tc = Integer.parseInt(br.readLine()); int cnt = 2; int endNumber = 0; if(tc == 1){ System.. 2022. 5. 7.
[백준] 2869번 달팽이는 올라가고 싶다 #Java import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.*; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine()); int a = Integer.parseInt(st.nextToken()); int b = Integer.parseInt(st.next.. 2022. 5. 7.
[백준] 10250번 ACM 호텔 #Java import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.readLine()); for (int i = 0; i < N; i++) { StringTokenizer st = new StringTokenizer(br.re.. 2022. 5. 7.