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_13848241_2289.c:2:59: error: expected identifier or '(' before '/' token
 int month_day[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};//begin with 1
                                                           ^
0_0_13848241_2289.c:3:64: error: expected identifier or '(' before '/' token
 int leap_month_day[13]={0,31,29,31,30,31,30,31,31,30,31,30,31};//begin with 1
                                                                ^
0_0_13848241_2289.c:11:98: error: expected identifier or '(' before '/' token
 char week_map[8][10]={"","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"};//begin with 1
                                                                                                  ^
0_0_13848241_2289.c:12:139: error: expected identifier or '(' before '/' token
 char month_map[13][10]={"","January","February","March","April","May","June","July","August","September","October","November","December"};//begin with 1
                                                                                                                                           ^
0_0_13848241_2289.c:14:1: error: unknown type name 'date'
 date date_start;
 ^
0_0_13848241_2289.c:15:1: error: unknown type name 'bool'
 bool is_leap(int year)
 ^
0_0_13848241_2289.c:20:15: error: expected declaration specifiers or '...' before 'date'
 int comp_date(date a,date b)
               ^
0_0_13848241_2289.c:20:22: error: expected declaration specifiers or '...' before 'date'
 int comp_date(date a,date b)
                      ^
0_0_13848241_2289.c:26:20: error: expected ')' before '&' token
 void walk_day(date &a,int growth)
                    ^
0_0_13848241_2289.c:62:26: error: expected ')' before '&' token
 int start_walk_rear(date &start,date &rear,int cmp)
                          ^
0_0_13848241_2289.c:67:5: error: missing terminating ' character
     //walk to year's start or end
     ^
0_0_13848241_2289.c:72:1: error: unknown type name 'bool'
 bool is_valid_date(date a)
 ^
0_0_13848241_2289.c:72:20: error: expected declaration specifiers or '...' before 'date'
 bool is_valid_date(date a)
                    ^
0_0_13848241_2289.c: In function 'main':
0_0_13848241_2289.c:82:15: error: request for member 'year' in something not a structure or union
     date_start.year=2014;date_start.month=9;date_start.day=9;date_start.week=2;
               ^
0_0_13848241_2289.c:82:36: error: request for member 'month' in something not a structure or union
     date_start.year=2014;date_start.month=9;date_start.day=9;date_start.week=2;
                                    ^
0_0_13848241_2289.c:82:55: error: request for member 'day' in something not a structure or union
     date_start.year=2014;date_start.month=9;date_start.day=9;date_start.week=2;
                                                       ^
0_0_13848241_2289.c:82:72: error: request for member 'week' in something not a structure or union
     date_start.year=2014;date_start.month=9;date_start.day=9;date_start.week=2;
                                                                        ^
0_0_13848241_2289.c:83:27: error: 'in_month' undeclared (first use in this function)
     while(scanf("%d%d%d",&in_month,&in_day,&in_year)!=EOF&&(in_year+in_month+in_day)>0)
                           ^
0_0_13848241_2289.c:83:27: note: each undeclared identifier is reported only once for each function it appears in
0_0_13848241_2289.c:83:37: error: 'in_day' undeclared (first use in this function)
     while(scanf("%d%d%d",&in_month,&in_day,&in_year)!=EOF&&(in_year+in_month+in_day)>0)
                                     ^
0_0_13848241_2289.c:83:45: error: 'in_year' undeclared (first use in this function)
     while(scanf("%d%d%d",&in_month,&in_day,&in_year)!=EOF&&(in_year+in_month+in_day)>0)
                                             ^
0_0_13848241_2289.c:85:14: error: expected ';' before 'date_end'
         date date_end;date_end.year=in_year;date_end.month=in_month;date_end.day=in_day;
              ^
0_0_13848241_2289.c:85:23: error: 'date_end' undeclared (first use in this function)
         date date_end;date_end.year=in_year;date_end.month=in_month;date_end.day=in_day;
                       ^
0_0_13848241_2289.c:89:42: error: 'month_map' undeclared (first use in this function)
             printf("%s %d, %d is a %s\n",month_map[date_end.month],date_end.day,date_end.year,week_map[date_end.week]);
                                          ^


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-09-28 15:30:31, Gzip enabled