diff --git "a/zinnnn37/202511/12 PGM LV2 \354\235\230\354\203\201.md" "b/zinnnn37/202511/12 PGM LV2 \354\235\230\354\203\201.md" new file mode 100644 index 00000000..94380c95 --- /dev/null +++ "b/zinnnn37/202511/12 PGM LV2 \354\235\230\354\203\201.md" @@ -0,0 +1,25 @@ +```java +import java.util.HashMap; +import java.util.Map; + +public class PGM_LV2_의상 { + + private static int ans; + private static Map clothes; + + public int solution(String[][] cl) { + clothes = new HashMap<>(); + ans = 1; + + for (String[] c : cl) { + clothes.put(c[1], clothes.getOrDefault(c[1], 0) + 1); + } + + for (String s : clothes.keySet()) { + ans *= clothes.get(s) + 1; + } + + return ans - 1; + } +} +``` \ No newline at end of file