From 72d092baa2601249dd220ceab42f5e495a211f88 Mon Sep 17 00:00:00 2001 From: oncsr Date: Fri, 14 Mar 2025 16:13:02 +0900 Subject: [PATCH] =?UTF-8?q?[20250314]=20BOJ=20/=20G4=20/=20=EB=91=90=20?= =?UTF-8?q?=EB=8C=80=ED=91=9C=20=EC=9E=90=EC=97=B0=EC=88=98=20/=20?= =?UTF-8?q?=EA=B6=8C=ED=98=81=EC=A4=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...4 \354\236\220\354\227\260\354\210\230.md" | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 "khj20006/202503/14 BOJ G4 \353\221\220 \353\214\200\355\221\234 \354\236\220\354\227\260\354\210\230.md" diff --git "a/khj20006/202503/14 BOJ G4 \353\221\220 \353\214\200\355\221\234 \354\236\220\354\227\260\354\210\230.md" "b/khj20006/202503/14 BOJ G4 \353\221\220 \353\214\200\355\221\234 \354\236\220\354\227\260\354\210\230.md" new file mode 100644 index 00000000..83e72d52 --- /dev/null +++ "b/khj20006/202503/14 BOJ G4 \353\221\220 \353\214\200\355\221\234 \354\236\220\354\227\260\354\210\230.md" @@ -0,0 +1,72 @@ +```java + +import java.util.*; +import java.io.*; + +class Main { + + // IO field + static BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); + static BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out)); + static StringTokenizer st = new StringTokenizer(""); + + static void nextLine() throws Exception {st = new StringTokenizer(br.readLine());} + static int nextInt() throws Exception { + if(!st.hasMoreTokens()) nextLine(); + return Integer.parseInt(st.nextToken()); + } + static long nextLong() throws Exception { + if(!st.hasMoreTokens()) nextLine(); + return Long.parseLong(st.nextToken()); + } + static void bwEnd() throws Exception {bw.flush();bw.close();} + + // Additional field + + static int N; + static long[] C; + + public static void main(String[] args) throws Exception { + + ready(); + solve(); + + bwEnd(); + + } + + static void ready() throws Exception{ + + N = nextInt(); + C = new long[10001]; + for(int i=0;i