F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_34778060_15246\Main.java:1: 错误: 需要class, interface或enum
public static void main(String args[])
              ^
0_0_34778060_15246\Main.java:4: 错误: 需要class, interface或enum
        Scanner in =new Scanner(System.in);
        ^
0_0_34778060_15246\Main.java:5: 错误: 需要class, interface或enum
        T=in.nextInt();
        ^
0_0_34778060_15246\Main.java:6: 错误: 需要class, interface或enum
        for (int i = 0; i < T; i++) {
        ^
0_0_34778060_15246\Main.java:6: 错误: 需要class, interface或enum
        for (int i = 0; i < T; i++) {
                        ^
0_0_34778060_15246\Main.java:6: 错误: 需要class, interface或enum
        for (int i = 0; i < T; i++) {
                               ^
0_0_34778060_15246\Main.java:8: 错误: 需要class, interface或enum
            System.out.print("Case #");
            ^
0_0_34778060_15246\Main.java:9: 错误: 需要class, interface或enum
            System.out.print(i+1);
            ^
0_0_34778060_15246\Main.java:10: 错误: 需要class, interface或enum
            System.out.print(": ");
            ^
0_0_34778060_15246\Main.java:11: 错误: 需要class, interface或enum
            String fir=in.next();
            ^
0_0_34778060_15246\Main.java:12: 错误: 需要class, interface或enum
            int y=Integer.parseInt(fir.substring(0,4));
            ^
0_0_34778060_15246\Main.java:13: 错误: 需要class, interface或enum
            int month=Integer.parseInt(fir.substring(5,7));
            ^
0_0_34778060_15246\Main.java:14: 错误: 需要class, interface或enum
            int day=Integer.parseInt(fir.substring(8,10));
            ^
0_0_34778060_15246\Main.java:15: 错误: 需要class, interface或enum
            fir=in.next();
            ^
0_0_34778060_15246\Main.java:16: 错误: 需要class, interface或enum
            int hour=Integer.parseInt(fir.substring(0,2));
            ^
0_0_34778060_15246\Main.java:17: 错误: 需要class, interface或enum
            int minute=Integer.parseInt(fir.substring(3,5));
            ^
0_0_34778060_15246\Main.java:18: 错误: 需要class, interface或enum
            int second=Integer.parseInt(fir.substring(6,8));
            ^
0_0_34778060_15246\Main.java:19: 错误: 需要class, interface或enum
            Date d=new Date();
            ^
0_0_34778060_15246\Main.java:20: 错误: 需要class, interface或enum
            d.setYear(y);
            ^
0_0_34778060_15246\Main.java:21: 错误: 需要class, interface或enum
            d.setMonth(month-1);
            ^
0_0_34778060_15246\Main.java:22: 错误: 需要class, interface或enum
            d.setDate(day);
            ^
0_0_34778060_15246\Main.java:23: 错误: 需要class, interface或enum
            int weekid=getWeek(d);
            ^
0_0_34778060_15246\Main.java:24: 错误: 需要class, interface或enum
            int start=getstart(y);
            ^
0_0_34778060_15246\Main.java:25: 错误: 需要class, interface或enum
            int end=getend(y);
            ^
0_0_34778060_15246\Main.java:26: 错误: 需要class, interface或enum
            if(month>=1&&month<=2||month==12){
            ^
0_0_34778060_15246\Main.java:28: 错误: 需要class, interface或enum
            }
            ^
0_0_34778060_15246\Main.java:31: 错误: 需要class, interface或enum
            }
            ^
0_0_34778060_15246\Main.java:35: 错误: 需要class, interface或enum
                    else if(day>start)ans=2;
                    ^
0_0_34778060_15246\Main.java:36: 错误: 需要class, interface或enum
                    else{
                    ^
0_0_34778060_15246\Main.java:38: 错误: 需要class, interface或enum
                        else if(hour>=3)ans=2;
                        ^
0_0_34778060_15246\Main.java:39: 错误: 需要class, interface或enum
                        else ans=0;
                        ^
0_0_34778060_15246\Main.java:40: 错误: 需要class, interface或enum
                    }
                    ^
0_0_34778060_15246\Main.java:44: 错误: 需要class, interface或enum
                    else if(day>end)ans=1;
                    ^
0_0_34778060_15246\Main.java:45: 错误: 需要class, interface或enum
                    else{
                    ^
0_0_34778060_15246\Main.java:47: 错误: 需要class, interface或enum
                        else if(hour<1)ans=2;
                        ^
0_0_34778060_15246\Main.java:48: 错误: 需要class, interface或enum
                        else ans=1;
                        ^
0_0_34778060_15246\Main.java:49: 错误: 需要class, interface或enum
                    }
                    ^
0_0_34778060_15246\Main.java:54: 错误: 需要class, interface或enum
            else if(ans==1) System.out.println("PST");
            ^
0_0_34778060_15246\Main.java:55: 错误: 需要class, interface或enum
            else if(ans==2) System.out.println("PDT");
            ^
0_0_34778060_15246\Main.java:56: 错误: 需要class, interface或enum
            else System.out.println("Both");
            ^
0_0_34778060_15246\Main.java:57: 错误: 需要class, interface或enum
        }
        ^
0_0_34778060_15246\Main.java:61: 错误: 需要class, interface或enum
    public static int getWeek(Date date)
                  ^
0_0_34778060_15246\Main.java:66: 错误: 需要class, interface或enum
        cal.setTime(date);
        ^
0_0_34778060_15246\Main.java:68: 错误: 需要class, interface或enum
        int week_index = cal.get(Calendar.DAY_OF_WEEK);
        ^
0_0_34778060_15246\Main.java:69: 错误: 需要class, interface或enum
        week_index-=2;
        ^
0_0_34778060_15246\Main.java:70: 错误: 需要class, interface或enum
        if (week_index<=0)week_index+=7;
        ^
0_0_34778060_15246\Main.java:71: 错误: 需要class, interface或enum
        return week_index;
        ^
0_0_34778060_15246\Main.java:73: 错误: 需要class, interface或enum
    }
    ^
0_0_34778060_15246\Main.java:74: 错误: 需要class, interface或enum
    public static int getstart(int year){
                  ^
0_0_34778060_15246\Main.java:76: 错误: 需要class, interface或enum
        d.setYear(year);
        ^
0_0_34778060_15246\Main.java:77: 错误: 需要class, interface或enum
        d.setMonth(Calendar.MARCH);
        ^
0_0_34778060_15246\Main.java:78: 错误: 需要class, interface或enum
        int cur=0;
        ^
0_0_34778060_15246\Main.java:79: 错误: 需要class, interface或enum
        for(int i=1;i<31;i++){
        ^
0_0_34778060_15246\Main.java:79: 错误: 需要class, interface或enum
        for(int i=1;i<31;i++){
                    ^
0_0_34778060_15246\Main.java:79: 错误: 需要class, interface或enum
        for(int i=1;i<31;i++){
                         ^
0_0_34778060_15246\Main.java:81: 错误: 需要class, interface或enum
            int id=getWeek(d);
            ^
0_0_34778060_15246\Main.java:82: 错误: 需要class, interface或enum
            if(id==7)cur++;
            ^
0_0_34778060_15246\Main.java:83: 错误: 需要class, interface或enum
            if(cur==2)return i;
            ^
0_0_34778060_15246\Main.java:84: 错误: 需要class, interface或enum
        }
        ^
0_0_34778060_15246\Main.java:86: 错误: 需要class, interface或enum
    }
    ^
0_0_34778060_15246\Main.java:87: 错误: 需要class, interface或enum
    public static int getend(int year){
                  ^
0_0_34778060_15246\Main.java:89: 错误: 需要class, interface或enum
        d.setYear(year);
        ^
0_0_34778060_15246\Main.java:90: 错误: 需要class, interface或enum
        d.setMonth(Calendar.NOVEMBER);
        ^
0_0_34778060_15246\Main.java:91: 错误: 需要class, interface或enum
        int cur=0;
        ^
0_0_34778060_15246\Main.java:92: 错误: 需要class, interface或enum
        for(int i=1;i<30;i++){
        ^
0_0_34778060_15246\Main.java:92: 错误: 需要class, interface或enum
        for(int i=1;i<30;i++){
                    ^
0_0_34778060_15246\Main.java:92: 错误: 需要class, interface或enum
        for(int i=1;i<30;i++){
                         ^
0_0_34778060_15246\Main.java:94: 错误: 需要class, interface或enum
            int id=getWeek(d);
            ^
0_0_34778060_15246\Main.java:98: 错误: 需要class, interface或enum
            if(id==7)cur++;
            ^
0_0_34778060_15246\Main.java:99: 错误: 需要class, interface或enum
            if(cur==1)return i;
            ^
0_0_34778060_15246\Main.java:100: 错误: 需要class, interface或enum
        }
        ^
0_0_34778060_15246\Main.java:102: 错误: 需要class, interface或enum
    }
    ^
72 个错误


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-12-03 11:01:55, Gzip enabled