본문 바로가기

분류 전체보기3718

[백준/Java] 6593번 상범 빌딩 -Codeimport java.io.*;import java.util.*;public class BOJ6593 { static class Pos { int height, row, col, time; public Pos (int height, int row, int col, int time) { this.height = height; this.row = row; this.col = col; this.time = time; } } static int heightSize; static int rowSize; static int colSize; static char.. 2026. 1. 24.
[백준/Java] 4179번 불! -Codeimport java.io.*;import java.util.*;public class BOJ4179 { static class PosInfo { int row, col; boolean isFire; public PosInfo(int row, int col, boolean isFire) { this.row = row; this.col = col; this.isFire = isFire; } } static int rowSize; static int colSize; static boolean[][] visited; static char[][] miro; .. 2026. 1. 23.
[백준/Java] 14503번 로봇 청소기 -Codeimport java.io.*;import java.util.*;public class BOJ14503 { static int[] dRow = {-1, 0, 1, 0}; static int[] dCol = {0, 1, 0, -1}; 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.n.. 2026. 1. 23.
[백준/Java] 4646번 Magnificent Meatballs -Codeimport java.io.*;import java.util.*;public class BOJ4646 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); while (true) { StringTokenizer st = new StringTokenizer(br.readLine()); int cnt = Integer.parseInt(st.nextToken()); // 탈출 조건 .. 2026. 1. 23.
[백준/Java] 5427번 불 -Codeimport java.io.*;import java.util.*;public class BOJ5427 { static class PosInfo { int row, col; boolean isFire; public PosInfo (int row, int col, boolean isFire) { this.row = row; this.col = col; this.isFire = isFire; } } static boolean[][] visited; static char[][] map; // 이동 방향 선언 static int[] dRow = {1, 0, -1, .. 2026. 1. 22.
[백준/Java] 1495번 기타리스트 -Codeimport java.io.*;import java.util.*;public class BOJ1495 { public static void main(String[] args) throws Exception { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine()); int songCnt = Integer.parseInt(st.nextToken()); int startVol = Integer.parseInt(st.nextToken()); .. 2026. 1. 22.