From cfd71e4c8a544e32c35285ebc1b25a4a874c2f65 Mon Sep 17 00:00:00 2001 From: LiiNi-coder <97495437+LiiNi-coder@users.noreply.github.com> Date: Sat, 25 Oct 2025 23:57:09 +0900 Subject: [PATCH] =?UTF-8?q?[20251025]=20PGM=20/=20LV2=20/=20=EC=B9=B4?= =?UTF-8?q?=ED=8E=AB=20/=20=EC=9D=B4=EC=9D=B8=ED=9D=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../25 PGM \354\271\264\355\216\253.md" | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 "LiiNi-coder/202510/25 PGM \354\271\264\355\216\253.md" diff --git "a/LiiNi-coder/202510/25 PGM \354\271\264\355\216\253.md" "b/LiiNi-coder/202510/25 PGM \354\271\264\355\216\253.md" new file mode 100644 index 00000000..0a79440e --- /dev/null +++ "b/LiiNi-coder/202510/25 PGM \354\271\264\355\216\253.md" @@ -0,0 +1,20 @@ +```java +class Solution { + public int[] solution(int brown, int yellow) { + int[] answer = new int[2]; + int area = brown + yellow; + for(int r = area/3; r>=3; r--){ + if(area % r == 0){ + int c = area / r; + System.out.println(r + "," + c); + if(2*c + (r-2)*2 == brown){ + System.out.println("FIND"); + answer[0] = c; + answer[1] = r; + } + } + } + return answer; + } +} +```