제출 #302605

#제출 시각아이디문제언어결과실행 시간메모리
302605ASD3D카니발 티켓 (IOI20_tickets)Java
컴파일 에러
0 ms0 KiB
public Class Problem { public static int find_maximum(int k, int[][] x) { int ans = 0; for (int i = 0; i < x.length; i++) { ans += x[i][0]; } ans -= x.length * x[x.length/2][0]; int[][] s = new int[x.length][1]; allocate_tickets(s); return ans; } }

컴파일 시 표준 에러 (stderr) 메시지

tickets.java:1: error: class, interface, or enum expected
public Class Problem {
       ^
tickets.java:2: error: class, interface, or enum expected
    public static int find_maximum(int k, int[][] x) {
                  ^
tickets.java:4: error: class, interface, or enum expected
        for (int i = 0; i < x.length; i++) {
        ^
tickets.java:4: error: class, interface, or enum expected
        for (int i = 0; i < x.length; i++) {
                        ^
tickets.java:4: error: class, interface, or enum expected
        for (int i = 0; i < x.length; i++) {
                                      ^
tickets.java:6: error: class, interface, or enum expected
        }
        ^
tickets.java:8: error: class, interface, or enum expected
        int[][] s = new int[x.length][1];
        ^
tickets.java:9: error: class, interface, or enum expected
        allocate_tickets(s);
        ^
tickets.java:10: error: class, interface, or enum expected
        return ans;
        ^
tickets.java:11: error: class, interface, or enum expected
    }
    ^
10 errors