Algorithm1 [알고리즘] 항상 효율적인 코드를 작성하자. 백준 알고리즘 2869번 문제를 풀게 되었다.사실, 문제만 보면 아주 간단한 문제이다. 그런데 정답 비율이 31%밖에 되질 않는다. 의문을 가지며 빠르게 아래 코드를 작성하고 제출해 보았다.class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(br.readLine(), " "); int A = Integer.parseInt(st.nextToken()); int B = In.. 2024. 7. 24. 이전 1 다음