criyle/codenet-compile-errors huggingface dataset:
Language: Java

mport java.util.*;
class Main{
        public static boolean judge(int y){
                if(y%3==0)      return true;
                return false;
        }
        public static int days(int y,int m,int d){
                int days = 0;
                for(int i=1;i<y;i++){
                        if(i%3==0){
                                days += 200;
                        }else{
                                days += 195;
                        }
                }
                if(y%3!=0){
                        for(int i=1;i<m;i++){
                                if(i%2==0)days+=19;
                                else days += 20;
                        }
                }else{
                        for(int i=1;i<m;i++){
                                days += 20;
                        }
                }
                days += d;
                return days;
        }
        public static void main(String[] args){
                Scanner sc = new Scanner(System.in);
                int today = days(1000,1,1);
                int n=sc.nextInt();
                for(int i=0;i<n;i++){
                        int ans = today - days(sc.nextInt(),sc.nextInt(),sc.nextInt());
                        System.out.println(ans);
                }

        }
}

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
mport java.util.*;
^
1 error
Language: C

#include <stdio.h>
#define USUAL_DAYS_OF_YEAR 195
#define UNUSUAL_DAYS_OF_YEAR 200
#define DAYS_OF_THREEYEARS 590
#define DAYS_OF_SMONTH 19
#define DAYS_OF_LMONTH 20


long CntDay(int y,int m,int d);
int main(){
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long yea,mon,day;
yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));mon=(10-m)*DAYS_OF_SMONTH+((y%3==0)?(10-m):((11-m)/2));day=((y%3==0)||(d%2==1))?(21-d):(20-d);
return yea+mon+day
}



}

Compiler output:
main.c: In function 'CntDay':
main.c:25:19: error: expected ';' before '}' token
   25 | return yea+mon+day
      |                   ^
      |                   ;
   26 | }
      | ~                  
main.c: At top level:
main.c:30:1: error: expected identifier or '(' before '}' token
   30 | }
      | ^
Language: C

#include <stdio.h>
#define USUAL_DAYS_OF_YEAR 195
#define UNUSUAL_DAYS_OF_YEAR 200
#define DAYS_OF_THREEYEARS 590
#define DAYS_OF_SMONTH 19
#define DAYS_OF_LMONTH 20


long CntDay(int y,int m,int d);
int main(){
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long yea,mon,day;
yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));mon=(10-m)*DAYS_OF_SMONTH+((y%3==0)?(10-m):((11-m)/2));day=((y%3==0)||(d%2==1))?(21-d):(20-d);
return yea+mon+day;
}



}

Compiler output:
main.c:30:1: error: expected identifier or '(' before '}' token
   30 | }
      | ^
Language: C

#include <stdio.h>
#define USUAL_DAYS_OF_YEAR 195
#define UNUSUAL_DAYS_OF_YEAR 200
#define DAYS_OF_THREEYEARS 590
#define DAYS_OF_SMONTH 19
#define DAYS_OF_LMONTH 20


long CntDay(int y,int m,int d);
int main(){
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long yea,mon,day;
yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));mon=(10-m)*DAYS_OF_SMONTH+((y%3==0)?(10-m):((11-m)/2));day=((y%3==0)||(d%2==1))?(21-d):(20-d);
return (yea+mon+day);
}



}

Compiler output:
main.c:30:1: error: expected identifier or '(' before '}' token
   30 | }
      | ^
Language: C

#include <stdio.h>

long CntDay(int y,int m,int d);

int main(){

int USUAL_DAYS_OF_YEAR 195;
int UNUSUAL_DAYS_OF_YEAR 200;
int DAYS_OF_THREEYEARS 590;
int DAYS_OF_SMONTH 19;
int DAYS_OF_LMONTH 20;
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long n,yea,mon,day;
yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
mon=(10-m)*DAYS_OF_SMONTH+(y%3==0)?(11-m):((11-m)/2);
day=1+((y%3==0)||(d%2==1))?(DAYS_OF_LMONTH-d):(DAYS_OF_SMONTH-d);
n=yea+mon+day;
return n;
}

Compiler output:
main.c: In function 'main':
main.c:7:24: error: expected '=', ',', ';', 'asm' or '__attribute__' before numeric constant
    7 | int USUAL_DAYS_OF_YEAR 195;
      |                        ^~~
main.c:8:26: error: expected '=', ',', ';', 'asm' or '__attribute__' before numeric constant
    8 | int UNUSUAL_DAYS_OF_YEAR 200;
      |                          ^~~
main.c:9:24: error: expected '=', ',', ';', 'asm' or '__attribute__' before numeric constant
    9 | int DAYS_OF_THREEYEARS 590;
      |                        ^~~
main.c:10:20: error: expected '=', ',', ';', 'asm' or '__attribute__' before numeric constant
   10 | int DAYS_OF_SMONTH 19;
      |                    ^~
main.c:11:20: error: expected '=', ',', ';', 'asm' or '__attribute__' before numeric constant
   11 | int DAYS_OF_LMONTH 20;
      |                    ^~
main.c: In function 'CntDay':
main.c:25:15: error: 'DAYS_OF_THREEYEARS' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |               ^~~~~~~~~~~~~~~~~~
main.c:25:15: note: each undeclared identifier is reported only once for each function it appears in
main.c:25:57: error: 'USUAL_DAYS_OF_YEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |                                                         ^~~~~~~~~~~~~~~~~~
main.c:25:76: error: 'UNUSUAL_DAYS_OF_YEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |                                                                            ^~~~~~~~~~~~~~~~~~~~
main.c:26:12: error: 'DAYS_OF_SMONTH' undeclared (first use in this function)
   26 | mon=(10-m)*DAYS_OF_SMONTH+(y%3==0)?(11-m):((11-m)/2);
      |            ^~~~~~~~~~~~~~
main.c:27:29: error: 'DAYS_OF_LMONTH' undeclared (first use in this function)
   27 | day=1+((y%3==0)||(d%2==1))?(DAYS_OF_LMONTH-d):(DAYS_OF_SMONTH-d);
      |                             ^~~~~~~~~~~~~~
Language: C

#include <stdio.h>

long CntDay(int y,int m,int d);

int main(){

int USUAL_DAYS_OF_YEAR = 195;
int UNUSUAL_DAYS_OF_YEAR = 200;
int DAYS_OF_THREEYEARS = 590;
int DAYS_OF_SMONTH = 19;
int DAYS_OF_LMONTH = 20;
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long n,yea,mon,day;
yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
mon=(10-m)*DAYS_OF_SMONTH+(y%3==0)?(11-m):((11-m)/2);
day=1+((y%3==0)||(d%2==1))?(DAYS_OF_LMONTH-d):(DAYS_OF_SMONTH-d);
n=yea+mon+day;
return n;
}

Compiler output:
main.c: In function 'CntDay':
main.c:25:15: error: 'DAYS_OF_THREEYEARS' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |               ^~~~~~~~~~~~~~~~~~
main.c:25:15: note: each undeclared identifier is reported only once for each function it appears in
main.c:25:57: error: 'USUAL_DAYS_OF_YEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |                                                         ^~~~~~~~~~~~~~~~~~
main.c:25:76: error: 'UNUSUAL_DAYS_OF_YEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYS_OF_THREEYEARS+((y%3==0)?0:((y%3==1)?(USUAL_DAYS_OF_YEAR+UNUSUAL_DAYS_OF_YEAR):UNUSUAL_DAYS_OF_YEAR));
      |                                                                            ^~~~~~~~~~~~~~~~~~~~
main.c:26:12: error: 'DAYS_OF_SMONTH' undeclared (first use in this function)
   26 | mon=(10-m)*DAYS_OF_SMONTH+(y%3==0)?(11-m):((11-m)/2);
      |            ^~~~~~~~~~~~~~
main.c:27:29: error: 'DAYS_OF_LMONTH' undeclared (first use in this function)
   27 | day=1+((y%3==0)||(d%2==1))?(DAYS_OF_LMONTH-d):(DAYS_OF_SMONTH-d);
      |                             ^~~~~~~~~~~~~~
Language: C

#include <stdio.h>

long CntDay(int y,int m,int d);

int main(){

int USUALDAYSOFYEAR = 195;
int UNUSUALDAYSOFYEAR = 200;
int DAYSOFTHREEYEARS = 590;
int DAYSOFSMONTH = 19;
int DAYSOFLMONTH = 20;
 int n,i,Year,Month,Day;
 scanf("%d\n",&n);
 i=1;
 while(i<=n){
  scanf("%d %d %d",&Year,&Month,&Day);
  printf("%ld\n", CntDay(Year,Month,Day));
  i++;
 }
 return 0;
}

long CntDay(int y,int m,int d){
long n,yea,mon,day;
yea=(999-y)/3*DAYSOFTHREEYEARS+((y%3==0)?0:((y%3==1)?(USUALDAYSOFYEAR+UNUSUALDAYSOFYEAR):UNUSUALDAYSOFYEAR));
mon=(10-m)*DAYSOFSMONTH+(y%3==0)?(11-m):((11-m)/2);
day=1+((y%3==0)||(d%2==1))?(DAYSOFLMONTH-d):(DAYSOFSMONTH-d);
n=yea+mon+day;
return n;
}

Compiler output:
main.c: In function 'CntDay':
main.c:25:15: error: 'DAYSOFTHREEYEARS' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYSOFTHREEYEARS+((y%3==0)?0:((y%3==1)?(USUALDAYSOFYEAR+UNUSUALDAYSOFYEAR):UNUSUALDAYSOFYEAR));
      |               ^~~~~~~~~~~~~~~~
main.c:25:15: note: each undeclared identifier is reported only once for each function it appears in
main.c:25:55: error: 'USUALDAYSOFYEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYSOFTHREEYEARS+((y%3==0)?0:((y%3==1)?(USUALDAYSOFYEAR+UNUSUALDAYSOFYEAR):UNUSUALDAYSOFYEAR));
      |                                                       ^~~~~~~~~~~~~~~
main.c:25:71: error: 'UNUSUALDAYSOFYEAR' undeclared (first use in this function)
   25 | yea=(999-y)/3*DAYSOFTHREEYEARS+((y%3==0)?0:((y%3==1)?(USUALDAYSOFYEAR+UNUSUALDAYSOFYEAR):UNUSUALDAYSOFYEAR));
      |                                                                       ^~~~~~~~~~~~~~~~~
main.c:26:12: error: 'DAYSOFSMONTH' undeclared (first use in this function)
   26 | mon=(10-m)*DAYSOFSMONTH+(y%3==0)?(11-m):((11-m)/2);
      |            ^~~~~~~~~~~~
main.c:27:29: error: 'DAYSOFLMONTH' undeclared (first use in this function)
   27 | day=1+((y%3==0)||(d%2==1))?(DAYSOFLMONTH-d):(DAYSOFSMONTH-d);
      |                             ^~~~~~~~~~~~
Language: C

#include <stdio.h>
int main(){
  int n, i, j, All=196471 , Y, M, D, sum;
  scanf("%d",&n);
  for(i = 0 ,sum = 0 ; i < n ; i++ , sum = 0){
  scanf("%d %d %d",&Y, &M, &D);
  /*テ・ツケツエテ」ツ?ョテヲツ敖。テ、ツサツカテ」ツ?ォテ」ツつ暗」ツ?」テ」ツ?ヲテヲツ?シテ・ツ?、テ」ツつ津、ツサツ」テ・ツ?・テ」ツ?陛」ツ?崚ァツカツ堙」ツ?妥」ツつ?/
  for(i = 1 ; i < Y ; i++){
    if(j % 3 == 0){
      sum+=200;
    }else{
      sum+=195;
    }
  }
  /*テヲツ慊暗」ツ?ョテヲツ敖。テ、ツサツカテ」ツ?ォ テ」ツつ暗」ツ?」テ」ツ?ヲテヲツ?シテ・ツ?、テ」ツつ津、ツサツ」テ・ツ?・テ」ツ?陛」ツ?崚ァツカツ堙」ツ?妥」ツつ?/
    for(j = 1 ; j < M ; j++){
      if(Y % 3 == 0|| j % 2 == 1){
	sum+=20;
      }else{
	sum+=19;
      }
    }
    /*テヲツ猟・テ、ツサツ佚」ツ?ョテヲツ敖。テ、ツサツカテ」ツ?ォ テ」ツつ暗」ツ?」テ」ツ?ヲテヲツ?シテ・ツ?、テ」ツつ津、ツサツ」テ・ツ?・テ」ツ?陛」ツ?崚ァツカツ堙」ツ?妥」ツつ?/
    sum+=D;
    printf("%d\n",All-sum);
  }
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:3: error: unterminated comment
    7 |   /*テ・ツケツエテ」ツ?ョテヲツ敖。テ、ツサツカテ」ツ?ォテ」ツつ暗」ツ?」テ」ツ?ヲテヲツ?シテ・ツ?、テ」ツつ津、ツサツ」テ・ツ?・テ」ツ?陛」ツ?崚ァツカツ堙」ツ?妥」ツつ?/
      |   ^
main.c:6:3: error: expected declaration or statement at end of input
    6 |   scanf("%d %d %d",&Y, &M, &D);
      |   ^~~~~
main.c:6:3: error: expected declaration or statement at end of input
Language: C

/*テヲツ敖。テ、ツサツカテ」ツ?ォテ」ツつ暗」ツ?」テ」ツ?ヲテ・ツ?、テ」ツつ津ィツソツステ・ツ環?」ツ?療ァツカツ堙」ツ?妥」ツつ?/
#include <stdio.h>
int main(){
  int n, i, j, All=196471 , Y, M, D, sum;
  scanf("%d",&n);
  for(j = 0 ,sum = 0 ; j < n ; j++ , sum = 0){
  scanf("%d %d %d",&Y, &M, &D);

  for(i = 1 ; i < Y ; i++){
    if(j % 3 == 0){
      sum+=200;
    }else{
      sum+=195;
    }
  }

    for(i = 1 ; i < M ; i++){
      if(Y % 3 == 0|| i % 2 == 1){
	sum+=20;
      }else{
	sum+=19;
      }
    }
  
    sum+=D;
    printf("%d\n",All-sum);
  }
  
  return 0;
}

Compiler output:
main.c:1:1: error: unterminated comment
    1 | /*テヲツ敖。テ、ツサツカテ」ツ?ォテ」ツつ暗」ツ?」テ」ツ?ヲテ・ツ?、テ」ツつ津ィツソツステ・ツ環?」ツ?療ァツカツ堙」ツ?妥」ツつ?/
      | ^
Language: C

#include<stdio.h>
int main(void)
{
  int i,j;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }

  for(i=0;i<100000;i++){
    for(j=0;j<100000;j++)
}

  return 0;
}
      

      

Compiler output:
main.c: In function 'main':
main.c:46:1: error: expected expression before '}' token
   46 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
  int i,j;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }
}

  for(i=0;i<100000;i++){
    for(j=0;j<100000;j++)

  return 0;
}
      

      

Compiler output:
main.c:45:3: error: expected identifier or '(' before 'for'
   45 |   for(i=0;i<100000;i++){
      |   ^~~
main.c:45:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   45 |   for(i=0;i<100000;i++){
      |            ^
main.c:45:21: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   45 |   for(i=0;i<100000;i++){
      |                     ^~
Language: C

#include<stdio.h>
int main(void)
{
  int i,j;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }
}

  for(i=0;i<100000;i++){
    for(j=0;j<100000;j++)
}

  return 0;
}
      

      

Compiler output:
main.c:45:3: error: expected identifier or '(' before 'for'
   45 |   for(i=0;i<100000;i++){
      |   ^~~
main.c:45:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   45 |   for(i=0;i<100000;i++){
      |            ^
main.c:45:21: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   45 |   for(i=0;i<100000;i++){
      |                     ^~
main.c:49:3: error: expected identifier or '(' before 'return'
   49 |   return 0;
      |   ^~~~~~
main.c:50:1: error: expected identifier or '(' before '}' token
   50 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
  int i,j;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }
}

  for(i=0;i<100000;i++){
    for(j=0;j<100000;j++){
    }
}

  return 0;
}
      

      

Compiler output:
main.c:45:3: error: expected identifier or '(' before 'for'
   45 |   for(i=0;i<100000;i++){
      |   ^~~
main.c:45:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   45 |   for(i=0;i<100000;i++){
      |            ^
main.c:45:21: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   45 |   for(i=0;i<100000;i++){
      |                     ^~
main.c:50:3: error: expected identifier or '(' before 'return'
   50 |   return 0;
      |   ^~~~~~
main.c:51:1: error: expected identifier or '(' before '}' token
   51 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
  int i,j;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }
}

  for(i=0;i<100000;i++)

  return 0;
}
      

      

Compiler output:
main.c:45:3: error: expected identifier or '(' before 'for'
   45 |   for(i=0;i<100000;i++)
      |   ^~~
main.c:45:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   45 |   for(i=0;i<100000;i++)
      |            ^
main.c:45:21: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   45 |   for(i=0;i<100000;i++)
      |                     ^~
main.c:48:1: error: expected identifier or '(' before '}' token
   48 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
  int i,j,k;
  int ymd[100][3], n, y3=590, date;

  scanf("%d", &n);
  for(i=0; i<n; i++) {
    for(j=0; j<3; j++) {
      scanf("%d", &ymd[i][j]);
    }
  }

  for(i=0;i<n;i++) {
    date = 0;
    date += ((ymd[i][0]-1)/3)*y3;
    switch(ymd[i][0]%3){
    case 2:
      date += 195;
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 1:
      for(j=0;j<ymd[i][1]-1;j++) {
	j%2 ? (date += 19):(date += 20);
      }
      date += ymd[i][2];
      break;
      
    case 0:
      date += 390;
      for(j=0;j<ymd[i][1]-1;j++) {
	date += 20;
      }
      date += ymd[i][2];
      break;
    }
    printf("%d\n", 196471 - date);
  }

  for(i=0;i<100000;i++) {
    for(j=0;j<100000;j++) k++;


  return 0;
}
      

Compiler output:
main.c: In function 'main':
main.c:49:1: error: expected declaration or statement at end of input
   49 | }
      | ^
Language: C

#include<stdio.h>
int main(void){
????int n,y,m,d,count;
????scanf("%d",&n);
????while(n--){
????????count=0;
????????scanf("%d%d%d",&y,&m,&d);
????????count=(y-1)*39*5;
????????count+=((y-1)/3)*1*5;
????????if(y%3==0){
????????????count+=(m-1)*20;
????????}
????????else{
????????????count+=(m-1)*20-(m-1)/2*1;
????????}
????????count+=d-1;
????????printf("%d\n",196470-count);
????}
????return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:1: error: expected expression before '?' token
    3 | ????int n,y,m,d,count;
      | ^
main.c:4:1: error: expected expression before '?' token
    4 | ????scanf("%d",&n);
      | ^
main.c:4:17: error: 'n' undeclared (first use in this function)
    4 | ????scanf("%d",&n);
      |                 ^
main.c:4:17: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:1: error: expected expression before '?' token
    5 | ????while(n--){
      | ^
Language: C

#include<stdio.h>
void AoD(int year,int month,int day);
int main(void){
  int y,m,d,i,data;

  scanf("%d",&data);
  for(i=1;i<=n;i++){
    scanf("%d %d %d",&y,&m,&d);
    AoD(y,m,d);
  }
}
void AoD(int year,int month,int day){
  int i,count;

  if(year%3==0)
    count = 20-day;
  else if(month%2!=0)
    count = 20-day;
  else
    count = 19-day;

  if(year%3==0)
    count += (10-month)*20;
  else if(month%2!=0)
    count += 19 + (10-month+1)/2*39;
  else
    count += (10-month)/2*39;

  if(year%3==0)
    count += (999-year)/3*580
  else if(year%3==1)
    count += 390 + (999-year+2)/3*580;
  else 
    count += 195 + (999-year+1)/3*580;

  count++;

  printf("%d\n",count);
}

Compiler output:
main.c: In function 'main':
main.c:7:14: error: 'n' undeclared (first use in this function)
    7 |   for(i=1;i<=n;i++){
      |              ^
main.c:7:14: note: each undeclared identifier is reported only once for each function it appears in
main.c: In function 'AoD':
main.c:30:30: error: expected ';' before 'else'
   30 |     count += (999-year)/3*580
      |                              ^
      |                              ;
   31 |   else if(year%3==1)
      |   ~~~~
Language: C

#include<iostream>
main(){int y,m,d;for(std::cin>>d;std::cin>>y>>m>>d;printf("%d\n",196490-d))d+=195*--y+y/3*5+19*m+m--/2+!(++y%3)*m/2;}

Compiler output:
main.c:1:9: fatal error: iostream: No such file or directory
    1 | #include<iostream>
      |         ^~~~~~~~~~
compilation terminated.
Language: C

main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}

Compiler output:
main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      | ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'y' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'm' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'd' defaults to 'int' [-Wimplicit-int]
main.c:1:17: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      |                 ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
main.c:1:17: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      |                 ^~~~~
main.c:1:17: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:1:58: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      |                                                          ^~~~~~
main.c:1:58: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:1:58: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:1:58: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:1:122: error: implicit declaration of function 'exit' [-Wimplicit-function-declaration]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      |                                                                                                                          ^~~~
main.c:1:1: note: include '<stdlib.h>' or provide a declaration of 'exit'
  +++ |+#include <stdlib.h>
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
main.c:1:122: warning: incompatible implicit declaration of built-in function 'exit' [-Wbuiltin-declaration-mismatch]
    1 | main(y,m,d){for(scanf("%d",&y);~scanf("%d%d%d",&y,&m,&d);printf("%d\n",196471-(--y)*195-y/3*5-(--m)*20+(y%3-2?m/2:0)-d));exit(0);}
      |                                                                                                                          ^~~~
main.c:1:122: note: include '<stdlib.h>' or provide a declaration of 'exit'
Language: C

#include <stdio.>

int main(void){
   int i,n;
   scanf("%d",&n);
   for(i=0;i<n;i++){
       int y,m,d,total=0;
       scanf("%d %d %d",&y,&m,&d);
       if(y%3 ==0){
          total +=(999-y)/3*590;
          total += (10-m)*20;
          total += 21-d;
      }
      else if(y%3 ==1){
          total +=(999-y+1)/3*590+395;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
       else if(y%3 ==2){
          total +=(999-y+2)/3*590+195;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
        printf("%d",total);
    }
  return 0;
}

Compiler output:
main.c:1:10: fatal error: stdio.: No such file or directory
    1 | #include <stdio.>
      |          ^~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>

int main(void){
   int i,n;
   scanf("%d",&n);
   for(i=0;i<n;i++){
       int y,m,d,total=0;
       scanf("%d %d %d",&y,&m,&d);
       if(y%3 ==0){
          total +=(999-y)/3*590;
          total += (10-m)*20;
          total += 21-d;
      }
      else if(y%3 ==1){
          total +=(999-y+1)/3*590+395;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
       else if(y%3 ==2){
          total +=(999-y+2)/3*590+195;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
        printf("%d",total);
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:37:1: error: expected declaration or statement at end of input
   37 | }
      | ^
main.c:37:1: error: expected declaration or statement at end of input
Language: C

#include <stdio.h>

int main(void)
{
   int i,n;
   scanf("%d",&n);
   for(i=0;i<n;i++){
       int y,m,d,total=0;
       scanf("%d %d %d",&y,&m,&d);
       if(y%3 ==0){
          total +=(999-y)/3*590;
          total += (10-m)*20;
          total += 21-d;
      }
      else if(y%3 ==1){
          total +=(999-y+1)/3*590+395;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
       else if(y%3 ==2){
          total +=(999-y+2)/3*590+195;
            if(m%2==1){
               total += 19+(9-m)/2*39;
               total += 21-d;
            }
            else if(m%2 ==0){
               total += (10-m)/2*39;
               total += 20-d;
            }
        printf("%d",total);
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:38:1: error: expected declaration or statement at end of input
   38 | }
      | ^
main.c:38:1: error: expected declaration or statement at end of input
Language: C

#include <stdio.h>
  int y,m,d,total;
void year(void){
    if(y%3==0){
      total+=(999-y)/3*590;
    }else if(y%3==1){
      total+=(997-y)/3*590;
      total+=395;
    }else if(y%3==2){
      total+=(998-y)/3*590;
      total+=200;
    }
}
void month(void){
    if(y%3==0){
       total+=(10-m)*20;
    }else{
       if(m%2==1){
       total+=(9-m)/2*39;
       total+=19;
       }
       else{
       total+=(10-m)/2*39;
       }
} 
void day(void){
      if(m%2==1)
        total+= 21-d;
      else
        total+=20-d;
}
int main(void)
  {
   int i,n;
   scanf("%d",&n);
   for(i=0;i<n;i++){
       total=0;
       scanf("%d %d %d",&y,&m,&d);
       year();
       month();
       day();
       printf("%d\n",total);
    }
  return 0;
}

Compiler output:
main.c: In function 'month':
main.c:45:1: error: expected declaration or statement at end of input
   45 | }
      | ^
Language: C

#include<stdio.h> 
 int n,y,m,d,i,total;
 void year(void){
   if(y%3==0){
      total+=(999-y)/3*590;
   }else if(y%3==1){
      total+=(998-y)/3*590+200;
   }else {
     total+=(997-y)/3*590+395;
   }
}
void month(void){
   if(y%3!=0){
    if(m%2==0){
     total+=(10-m)/2*39;
    }else{
     total+=(9-m)/2*39+19;
    }
   }else{
     total+=(10-m)*20;
   }
}
void day(void){
  if(y%3!=0){
    if(m%2==0){
       total+=20-d;
      }else{
          total+=21-d;
     }
   }else{
       total+=21-d;
   }
}
int main(void){

  scanf("%d",&n);
    for(i=0;i<n;i++){
         total=0;
         scanf("%d %d %d",&y,&m,&d);
         year();
         month(); 
         day();
         printf("%d\n",total);
     }
   return 0:
}

    

Compiler output:
main.c: In function 'main':
main.c:45:12: error: expected ';' before ':' token
   45 |    return 0:
      |            ^
      |            ;
Language: C

main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}

Compiler output:
main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      | ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'Y' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'M' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'D' defaults to 'int' [-Wimplicit-int]
main.c:1:17: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                 ^~~~
main.c:1:23: error: 'i' undeclared (first use in this function)
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                       ^
main.c:1:23: note: each undeclared identifier is reported only once for each function it appears in
main.c:1:27: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                           ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
main.c:1:27: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                           ^~~~~
main.c:1:27: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:1:52: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                                                    ^~~~~~
main.c:1:52: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:1:52: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:1:52: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}

Compiler output:
main.c:1:1: warning: data definition has no type or storage class
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      | ^
main.c:1:1: error: type defaults to 'int' in declaration of 'Y' [-Wimplicit-int]
main.c:1:3: error: return type defaults to 'int' [-Wimplicit-int]
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |   ^~~~
main.c: In function 'main':
main.c:1:3: error: type of 'M' defaults to 'int' [-Wimplicit-int]
main.c:1:3: error: type of 'D' defaults to 'int' [-Wimplicit-int]
main.c:1:17: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                 ^~~~
main.c:1:23: error: 'i' undeclared (first use in this function)
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                       ^
main.c:1:23: note: each undeclared identifier is reported only once for each function it appears in
main.c:1:29: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                             ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
main.c:1:29: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                             ^~~~~
main.c:1:29: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:1:54: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    1 | Y;main(M,D){for(gets(&i);Y=~scanf("%d%d%d",&Y,&M,&D);printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                                                      ^~~~~~
main.c:1:54: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:1:54: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:1:54: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}

Compiler output:
main.c:1:1: error: return type defaults to 'int' [-Wimplicit-int]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      | ^~~~
main.c: In function 'main':
main.c:1:1: error: type of 'Y' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'M' defaults to 'int' [-Wimplicit-int]
main.c:1:1: error: type of 'D' defaults to 'int' [-Wimplicit-int]
main.c:1:17: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                 ^~~~
main.c:1:23: error: 'i' undeclared (first use in this function)
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                       ^
main.c:1:23: note: each undeclared identifier is reported only once for each function it appears in
main.c:1:27: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                           ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
main.c:1:27: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                           ^~~~~
main.c:1:27: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:1:54: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    1 | main(Y,M,D){for(gets(&i);~scanf("%d%d%d",&Y,&M,&D)*Y;printf("%d\n",196686-Y*195-(Y-1)/3*5-M*20+(Y%3?--M/2:0)-D));}
      |                                                      ^~~~~~
main.c:1:54: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:1:54: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:1:54: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

# include <stdio.h>


int y[100], m[100], d[100], out[100];


void input(int n){
	scanf("%d%d%d", y[n], m[n], d[n]);
}

void output(int n){
	printf("%d\n", out[n]);
}

int main(void){

	int n, i, num;
	int year, month, day;

	scanf("%d", &n);

	for(i=0; i<n; i++){
		input(n);
	}

	for(i=0; i<n; i++){

		if(y[i] % 3 == 0){
			num = 20;
		}
		else if(m[i] % 2 == 0){
			num = 19;
		}else{
			num = 20;
		}
		out[i] += (num - day[i]);

		for(year=y[i]; year<1000; year++){
			for(month=m[i]+1; month<10; month++){
				if(year % 3 == 0){
					num = 20;
				}
				else if(month % 2 == 0){
					num = 19;
				}else{
					num = 20;
				}
				out[i] += num;
			}
		}
	}




	for(i=0; i<n; i++){
		output(n);
	}

	return -1;
}

Compiler output:
main.c: In function 'main':
main.c:36:37: error: subscripted value is neither array nor pointer nor vector
   36 |                 out[i] += (num - day[i]);
      |                                     ^
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main() {

    int n, y, m, d;
    int sum_day;

    cin >> n;

    while(n--) {
        cin >> y >> m >> d;
        sum_day = 0;

        for(int i = y; i < 1000; ++i) {
            for(int j = (i == y ? m : 1); j <= 10; j++) {
                for(int k = (i == y && j == m ? d : 1); k <= (i % 3 ? 20 - (1 - j % 2) : 20); ++k) {
                    ++sum_day;
                }
            }
        }

        cout << sum_day << endl;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:25:6: error: expected '}' at end of input
   25 |     }
      |      ^
a.cc:5:12: note: to match this '{'
    5 | int main() {
      |            ^
Language: C++

#include<iostream>
//#include<fstream>

using namespace std;

int main() {
	//??§??????:20??\
	//?°???????:19??\
	//1??´:195??\
	//3??§?????????????????´:200??\

	//ifstream fin("in.txt");

	int n = 0;
	fin >> n;

	//1000??´????????\??°
	const int allday = 196471;// = 195 * 666 + 200 * 333 + 1

	for (int i = 0; i < n; i++) {

		int y, m, d;
		cin >> y >> m >> d;

		y--;
		int ans = 590 * (y / 3) + 195 * (y % 3);

		m--;
		ans = y % 3 == 2 ? ans + 20 * m : ans + 39 * (m / 2) + 20 * (m % 2);

		ans += d;

		cout << allday - ans << endl;
	}


	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:9: error: 'fin' was not declared in this scope
   15 |         fin >> n;
      |         ^~~
Language: C++

// foo.cpp : コンソール アプリケーションのエントリ ポイントを定義します。
//

#include "stdafx.h"
#include <iostream>
using namespace std;

int _tmain(int argc, _TCHAR* argv[])
{
	int n,y,m,d;
	int y3,yd,m2,md,dd,y2;

	cin >> n;

	for(int i=0;i<n;i++){
		cin >> y >> m >> d;

		if(y%3!=0)	y2=y+(3-y%3);
		else y2=y;
		y3 = 334-y2/3;
		yd = y3*200 + (1000-y-y3)*195;

		m2 = m/2;
		if(y%3!=0){
			md = yd-39*m2;
			if(m%2==1){
				dd = md-d+1;
			}else{
				dd = md + (19-d+1);
			}
		}else{
			md = yd-20*m;
			dd = md+20-d+1;
		}
		cout << dd << endl;
	}

	return 0;
}

Compiler output:
a.cc:4:10: fatal error: stdafx.h: No such file or directory
    4 | #include "stdafx.h"
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
using namespace std;

int sum(int y, int m, int d) {
	int t = 0;
	t += (y - 1) * 195 + (y - 1) / 3 * 5;
	t += (m - 1) * 19 + m / 2;
	if (y % 3 == 0) t += (m - 1) / 2;
	t += d - 1;
	return t;
}

int main() {
	int n;
	cin >> n;
	if (n == 0) break;
	while (n--) {
		int y, m, d;
		cin >> y >> m >> d;
		
		cout << sum(1000, 1, 1) - sum(y, m, d) << endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:21: error: break statement not within loop or switch
   16 |         if (n == 0) break;
      |                     ^~~~~
Language: C++

#include<iostream>
#include<vector>
#include<string>
#include<algorithm>
using namespace std;
#define base 196471
int n;
int main() {

	cin >> n;
	int Y, M, D;
	vector<int> ans;
	while (n--) {
		int tmp = 0;
		cin >> Y >> M >> D;
		tmp += (Y % 3 && !(M % 2)) ? 20 - D : 21 - D;
		for (int i = M+1; i <= 10; ++i) {
			tmp += (Y % 3 && !(i % 2)) ? 19 : 20;
		}
		for (int i = Y + 1; i <= 999; ++i) {
			tmp += (i % 3) ? 195 : 200;
		}
		ans.push_back(tmp);
	}
	for (int i = 0; i < ans.size(); ++i) {
		cout << ans[i] << endl;
	}
	return 0;


Compiler output:
a.cc: In function 'int main()':
a.cc:28:18: error: expected '}' at end of input
   28 |         return 0;
      |                  ^
a.cc:8:12: note: to match this '{'
    8 | int main() {
      |            ^
Language: C++

#include<iostream>
using namespace std;
struct PEO{
       int ye;
       int mon;
       int day;} peo[200]; 
int main(){
      int t[200];      //time peo have lived 
      int n;
      cin>>n;        //imput the number of the people 
      for(int i=0;i<n;i++) {
			cin >> peo[i].ye >> peo[i].mon>>peo[i].day;} //save year month day
      for(int i=0;i<n;i++){
      t[i]=(((peo[i].ye-1)/3)*200+(peo[i].ye-1-((peo[i].ye-1)/3))*195+(((peo[i].mon-1)/2)*20+(peo[i].mon-1-(peo[i].mon-1)/2))*19)+peo.day-1) ; 
      } 
      for(int i=0;i<n;i++){
      cout<< 196471-t[i]<<endl; 
      } 
      getchar;getchar;
      return 0;  
} 
 

Compiler output:
a.cc: In function 'int main()':
a.cc:14:135: error: request for member 'day' in 'peo', which is of non-class type 'PEO [200]'
   14 |       t[i]=(((peo[i].ye-1)/3)*200+(peo[i].ye-1-((peo[i].ye-1)/3))*195+(((peo[i].mon-1)/2)*20+(peo[i].mon-1-(peo[i].mon-1)/2))*19)+peo.day-1) ;
      |                                                                                                                                       ^~~
Language: C++

gets.to_i.times {
	y,m,d = gets.split(' ').map(&:to_i)
	d += (y-1)/3*590+(y-1)%3*195 
	d += y%3 == 0 ? (m-1)*20 : (m-1)*19 + m/2
	puts 196471-d
}

Compiler output:
a.cc:1:1: error: 'gets' does not name a type
    1 | gets.to_i.times {
      | ^~~~
Language: C++

#include <iostream>

int main(){
	int n;
	cin>>n;
	while(n--){
		int y,m,d,cnt=0;
		cin>>y>>m>>d;
		if(y % 3 == 0) {
				cnt += (21 - d);
		}
		else {
				cnt += ((m % 2 == 0 ? 20 : 21) - d);
		}
		for(int i = m + 1; i <= 10; i++) {
				if(y % 3 == 0) {
						cnt += 20;
				}
				else{
						if(i % 2 == 0) {
								cnt += 19;
						}
						else {
								cnt += 20;
						}
				}

		}
		for(int i = y + 1; i <= 999; i++) {
				if(i % 3 == 0) {
						cnt += 20 * 10;
				}
				else {
						cnt += 20 * 5 + 19 * 5;
				}
		}
		cout<<cnt<<endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |         cin>>n;
      |         ^~~
      |         std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:37:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   37 |                 cout<<cnt<<endl;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:37:28: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   37 |                 cout<<cnt<<endl;
      |                            ^~~~
      |                            std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <string>
#include <vector>
#include<iostream>
#include<cstdio>
#include<cstdlib>
#include<stack>
#include<queue>
#include<cmath>
#include<algorithm>
#include<functional>
//--
#include<list>
#include<deque>
#include<bitset>
#include<set>
#include<map>
#include<cstdio>
#include<cstring>
#include<sstream>
#define X first
#define Y second
#define pb push_back

using namespace std;
typedef __int64 ll;

int n,y,m,d,sum,days;

int main(){
  scanf("%d",&n);
  while(n--){
    scanf("%d %d %d",&y,&m,&d);
    sum=0;
    for(;y<1000;y++){
      for(;m<=10;m++){
        days=19+(y%3==0 || m%2==1);
        for(;d<=days;d++){
          sum++;
        }
        d=1;
      }
      m=1;
    }
    printf("%d\n",sum);
  }
  return 0;
}

Compiler output:
a.cc:25:9: error: '__int64' does not name a type; did you mean '__int64_t'?
   25 | typedef __int64 ll;
      |         ^~~~~~~
      |         __int64_t
Language: C++

#include <iostream>
#define MAX 196470

using namespace std;

int main(void){

  int n;
  cin >> n;

 while(n--){
   int y,m,d;
   cin >> y >> m >> d;
   y--; m--; d--;
   int day = 0;
   day += ( 20*5 + 19*5) * y;
   day += (y/3) * 5;
   day += m * 20;
   if( (y + 1) % 3 != 0 ) day -= (m/2);
   day += d;
   cout << N - day << endl;
 }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:12: error: 'N' was not declared in this scope
   21 |    cout << N - day << endl;
      |            ^