Study & Project ✏️/알고리즘 📋 44

백준[JAVA] 1018.체스판 다시 칠하기 - 자바

📖 문제 📃 코드 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.StringTokenizer; public class Main { static boolean[][] arr; static int min = 64; public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine(), " "); ..

백준[JAVA] 4153.직각삼각형- 자바

📖 문제 📃 코드 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; import java.util.StringTokenizer; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st; int[] arr = new int[3]; while (true) { st = new StringTokenize..

백준[JAVA] 1436.영화감독 숌- 자바

📖 문제 📃 코드 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; 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()); int MovieName = makeMovieName(N); System.out.println(MovieName); } private static int makeMovieName(..

백준[JAVA] 10814.나이순 정렬- 자바

📖 문제 📃 코드 import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; import java.util.Comparator; import java.util.StringTokenizer; public class Main { static String[][] arr; public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int N = Integer.parseInt(br.re..

백준[JAVA] 2609.최대공약수와 최소공배수 - 자바

📖 문제 📃 코드 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)); StringTokenizer st = new StringTokenizer(br.readLine()); int a = Integer.parseInt(st.nextToken()); int b = ..

백준[JAVA] 1929.소수 구하기 - 자바

📖 문제 📃 코드 1. Bruteforce + sqrt 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)); StringTokenizer st = new StringTokenizer(br.readLine(), " "); int M = Integer.parseInt..