From c4526e90e5a41308bf2f1accb6096582ea3f5fe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=97=BC=ED=98=9C=EC=A0=95?= <122238744+cyzlcyzl@users.noreply.github.com> Date: Wed, 9 Sep 2026 23:53:46 +0900 Subject: [PATCH] Create Code Testcase Testcase Test Result 2525. Categorize Box According to Criteria.java --- ...Categorize Box According to Criteria.java" | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 "leetcode3/\354\227\274\355\230\234\354\240\225/Code Testcase Testcase Test Result 2525. Categorize Box According to Criteria.java" diff --git "a/leetcode3/\354\227\274\355\230\234\354\240\225/Code Testcase Testcase Test Result 2525. Categorize Box According to Criteria.java" "b/leetcode3/\354\227\274\355\230\234\354\240\225/Code Testcase Testcase Test Result 2525. Categorize Box According to Criteria.java" new file mode 100644 index 00000000..3c10fa1d --- /dev/null +++ "b/leetcode3/\354\227\274\355\230\234\354\240\225/Code Testcase Testcase Test Result 2525. Categorize Box According to Criteria.java" @@ -0,0 +1,23 @@ +// O(1) + +class Solution { + public String categorizeBox(int length, int width, int height, int mass) { + boolean bulky = false; + + if (length >= 10000 || width >= 10000 || height >= 10000) { + bulky = true; + } + + long volume = (long) length * width * height; + if (volume >= 1_000_000_000L) { + bulky = true; + } + + boolean heavy = mass >= 100; + + if (bulky && heavy) return "Both"; + if (bulky) return "Bulky"; + if (heavy) return "Heavy"; + return "Neither"; + } +}