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

#include <cstdio>
#include <cstring>
#include <iostream>
#include <cmath>
#include <algorithm>
#include <queue>
#include <vector>
#include <utility>
using namespace std;

const int maxn = 105500;
const int maxe = 1e6+100;
const int INF  = 0x3f3f3f3f;

int dp1[maxn];
int dp2[maxn];
int prime[maxn];
int cnt = 1;


bool is_prime(int temp)
{
	int factor;
	bool flag=true;
	if(temp==2)
		flag=true;
	else if(temp==1||temp%2==0)
		flag=false;
	else
	{
        int m=(int)(sqrt((double)temp)+0.5);
		for(factor=3;factor<=m;factor+=2)
		{
			if(temp%factor==0)
			{
				flag=false;
				break;
			}
		}
	}
	return flag;
}


int main()
{

   // freopen("E:\\acm\\output.txt","w",stdout);
    memset(dp1,0,sizeof(dp1));
    memset(dp2,0,sizeof(dp2));


    for(int i=2;i<=80000;i++){
        if(is_prime(i))
            prime[cnt++] = i;
    }
    int ans = 0;
    for(int i=2;i<=80000;i++)
    {
        ans = 0;
        if(is_prime(i)) ans++;
        for(int k=1;k<cnt;k++){
            if(prime[k] > i) break;
            for(int j=k;j<cnt;j++){
                if(prime[j]> i ) break;
                if(prime[k] + prime[j] == i) ans++;
                if(prime[k] * prime[j] == i) ans++;
            }
        }
        for(int k=1;k<cnt;k++){
            if(prime[k]>i) break;
            for(int j=k;j<cnt;j++){
                if(prime[j]>i || prime[k]+prime[j]>i) break;
                for(int m=j;m<cnt;m++){
                    if(prime[m]>i || prime[m]+prime[k]>i || prime[m]+prime[j]>i) break;
                    if(prime[k] + prime[j] + prime[m] == i) ans++;
                    if(prime[k] * prime[j] * prime[m] == i) ans++;
                    if(prime[k] == prime[j] && prime[j] == prime[m]){
                        if(prime[k] * prime[j] + prime[m] == i) ans++;
                        continue;
                    }
                    if(prime[k] == prime[j]){
                        if(prime[k] * prime[j] + prime[m] == i) ans++;
                        if(prime[k] * prime[m] + prime[j] == i) ans++;
                        continue;
                    }
                    if(prime[k] == prime[m]){
                        if(prime[k] * prime[j] + prime[m] == i) ans++;
                        if(prime[k] * prime[m] + prime[j] == i) ans++;
                        continue;
                    }
                    if(prime[m] == prime[j]){
                        if(prime[m] * prime[j] + prime[k] == i) ans++;
                        if(prime[k] * prime[m] + prime[j] == i) ans++;
                        continue;
                    }
                    if(prime[k] * prime[j] + prime[m] == i) ans++;
                    if(prime[k] * prime[m] + prime[j] == i) ans++;
                    if(prime[m] * prime[j] + prime[k] == i) ans++;
                }

            }
        }
        printf("%d,",ans);
    }
}

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

#include<iostream>
#include<string.h>
#include<stdio.h>
using namespace std;
int next[100];
void getnext(char *t)
{
	next[0]=-1;
	int j=0,k=-1;
	while(j<strlen(t))
	{	
		if((k==-1)||(t[j]==t[k]))
		{
			j++;k++;
      next[j]=k;
		}
		else
			k=next[k];
	}
}
int kmp(char *t,char *p)
{
	int i=0,j=0,l1=strlen(t),l2=strlen(p);
	while(i<l1&&j<l2)
	{
		if(j==-1||t[i]==p[j])
		{
			i++;
			j++;
		}
		else
			j=next[j];
	}
	if(j>=l2)
		return i-l2;
	else
		return -1;
}
int main()
{
	char a[100],c[100];
	int i,j;
	cin>>a>>c;
	getnext(c);
	for(i=0;i<strlen(c)+1;i++)
		cout<<next[i]<<" ";
	cout<<endl;
	//cout<<kmp(a,c)<<endl;
	
	return 0;
}

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

#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <algorithm>
using namespace std;

const double eps = 1e-9;
const double D = 42.5;
const double R1 = 10.0;
const double R2 = 6.0;
const double pi = acos(-1.0);
inline int sig(double x) { return (x>eps)-(x<-eps) ;}

double x, t;

void deal()
{
    x = x/180 * pi;
    double ps;
    double k = tan(x);
    double s = D/k;
    t *= 100;
    int pp = t/s;
    double lls;
    lls = (pp&1)? (t-(pp-1)*s) : (t-pp*s);
    if(16 > lls + eps)
    {
        puts("yes");
        return ;
    }
    double y1 = 0.0;
    int tt = pp;
    tt >>= 1;
    if(tt & 1)
    {
        k = -k;
        if(pp&1)    y1 = -42.5;
    }
    else
    {
        if(pp&1)    y1 = 42.5;
    }
    double dd = lls * sin(x);
    double sd = y1 - k*lls;
    double fx = -sd / (k + 1.0/ k);
    if(fx-eps < 0)  ps = sd;
    else    ps = dd;
    if(ps-eps < 16) puts("yes");
    else    puts("no");
}

int main()
{
    int n;
    freopen("in1.txt", "r", stdin);
    scanf("%d", &n);
    while(n--)
    {
        scanf("%lf %lf", &t, &x);
        deal();
    }
    return 0;
}

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

#include<iostream>
#include<stdio.h>
#include<string.h>
#include<algorithm>
using namespace std;
const int N = 550000;
char a[N],s1[N],s2[N],nx[N];
int ans[N],l,next[N];
inline void get_next(char *s)
{
    next[0]=-1;
    int i=0,j=-1;
    while(s[i])
    {
        if(j==-1||s[i]==s[j]) next[++i]=++j;
        else j=next[j];
    }
}
inline int kmp()
{
    int ret=0;
    get_next(s1);
    for(int i=0,j=0;s2[i];++i)
    {
        if(j==-1||s2[i]==s1[j]) ++i,++j;
        else j=next[j];
        if(!s1[j])
        {
            ++ret;
            j=0;
        }
    }
    return ret;
}
bool judge()
{
    int ret=kmp();
    return ret==1;
}
int main()
{
    int T;
    scanf("%d",&T);
    while(T--)
    {
        scanf("%s%s%s",a,s1,s2);
        int len=strlen(a);
        for(int i=0;i<len;++i)
            nx[a[i]]=a[(i+1)%len];
        l=0;
        cout<<len<<endl;
        for(int i=0;i<len;++i)
        {
            cout<<"s1="<<s1<<endl;
            cout<<"s2="<<s2<<endl;
            if(judge()) ans[l++]=i;
            for(int j=0;j<s1[j];++j)
                s1[j]=nx[s1[j]];
        }
        if(l==0) puts("no solution");
        else if(l==1) printf("unique: %d\n",ans[0]);
        else{
            printf("ambiguous:");
            for(int i=0;i<l;++i)
                printf(" %d",ans[i]);
            puts("");
        }
    }
}

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

#include<iostream>
#include<stdio.h>
#include<algorithm>
#include<bitset>
using namespace std;
const int N = 500;
int dir[4][2]={-1,0,0,1,1,0,0,-1};
int vis[N][N],d[N][N],n,m;
char s[N][N];
bitset<N> bt;
bool ys;
bool judge(int x,int y)
{
    return x>=0&&y>=0&&x<n&&y<m;
}
void dfs(int x,int y,int &l)
{
//    cout<<x<<" "<<y<<endl;
    vis[x][y]=1;
    bt.set(s[x][y]-'0');
    ++l;
    for(int i=0;i<4;++i)
    {
        if(d[x][y]&(1<<i))
        {
            int nx=x+dir[i][0];
            int ny=y+dir[i][1];
            if(!judge(x,y)) ys=0;
            if(judge(x,y)&&!vis[nx][ny])
                dfs(nx,ny,l);
        }
    }
}
int main()
{
    int T;
//    freopen("1.in","r",stdin);
    scanf("%d",&T);
    while(T--)
    {
        scanf("%d%d",&n,&m);
        for(int i=0;i<n;++i)
            scanf("%s",s[i]);
        for(int i=0;i<n;++i)
            for(int j=0;j<m;++j)
                scanf("%d",&d[i][j]),vis[i][j]=0;
        ys=1;
        for(int x=0;x<n&&ys;++x)
            for(int y=0;y<m&&ys;++y)
                for(int k=0;k<4&&ys;++k)
                    if(d[x][y]&(1<<k))
                    {
                        int nx=x+dir[k][0];
                        int ny=y+dir[k][1];
                        if(!judge(nx,ny)) ys=0;
                        else{
                            int nk=(k+2)%4;
                            if(!(d[nx][ny]&(1<<nk))) ys=0;
                        }
                    }
        for(int x=0;x<n;++x)
            for(int y=0;y<m;++y)
                for(int nx=x+1;nx<n;++nx){
                    if(s[x][y]==s[nx][y]&&(s[x][y]-'0')>nx-x)
                        ys=0;
                }
        for(int x=0;x<n;++x)
            for(int y=0;y<m;++y)
                for(int ny=y+1;ny<m;++ny){
                    if(s[x][y]==s[x][ny]&&(s[x][y]-'0')>ny-y)
                        ys=0;
                }
        for(int i=0;i<n&&ys;++i)
            for(int j=0;j<m&&ys;++j)
            {
                if(!vis[i][j])
                {
                    int l=0;
                    bt.reset();
                    dfs(i,j,l);
//                    puts("--------");
                    for(int i=l;i>0;--i)
                    {
                        if(bt[i]) --l;
                    }
                    if(l>0)
                        ys=0;
                }
            }
        if(ys) puts("valid");
        else puts("invalid");
    }
}

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

#include<iostream>
#include<cstdio>
using namespace std;

//31,37,41,43,47
const int N = 1000;
const int mod = 5;
int f[N][N];
int bell[N];
int main()
{
	freopen("out.txt","w",stdout);
	f[0][0]=1;
	for(int i=1;i<N;i++){
		for(int k=1;k<=i;k++){
			f[i][k] =( k * f[i-1][k] + f[i-1][k-1])%mod;;
		}
	}

	for(int i=0;i<10;i++){
		for(int j=0;j<=i;j++)cout<<f[i][j]<<' ';cout<<endl;
	}

	bell[0]=1;
	for(int i=1;i<N;i++){
		for(int j=0;j<=i;j++){
			bell[i] = (bell[i]+f[i][j])%mod;
		}
	}
	for(int i=0;i<100;i++)cout<<bell[i]<<endl;
}

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

BELL[1] = 1
BELL[2] = 2
BELL[3] = 5
BELL[4] = 15
BELL[5] = 52
BELL[6] = 203
BELL[7] = 877
BELL[8] = 4140
BELL[9] = 21147
BELL[10] = 115975
BELL[11] = 678570
BELL[12] = 4213597
BELL[13] = 27644437
BELL[14] = 816188
BELL[15] = 52376607
BELL[16] = 25569777
BELL[17] = 83664947
BELL[18] = 58521367
BELL[19] = 41238267
BELL[20] = 66393230
BELL[21] = 44010570
BELL[22] = 24269368
BELL[23] = 65243549
BELL[24] = 30593854
BELL[25] = 76037701
BELL[26] = 88240771
BELL[27] = 38218614
BELL[28] = 38251537
BELL[29] = 16003483
BELL[30] = 94585219
BELL[31] = 88100886
BELL[32] = 46712942
BELL[33] = 80811365
BELL[34] = 30515924
BELL[35] = 35376864
BELL[36] = 21292729
BELL[37] = 82094381
BELL[38] = 61344190
BELL[39] = 19952738
BELL[40] = 78396064
BELL[41] = 60872948
BELL[42] = 36180002
BELL[43] = 6647501
BELL[44] = 56411961
BELL[45] = 29448686
BELL[46] = 76937985
BELL[47] = 65229046
BELL[48] = 92952796
BELL[49] = 33003924
BELL[50] = 5069299

Compiler output:
main.c:1:1: warning: data definition has no type or storage class
    1 | BELL[1] = 1
      | ^~~~
main.c:1:1: error: type defaults to 'int' in declaration of 'BELL' [-Wimplicit-int]
main.c:1:11: error: invalid initializer
    1 | BELL[1] = 1
      |           ^
main.c:2:1: error: expected ',' or ';' before 'BELL'
    2 | BELL[2] = 2
      | ^~~~
Language: C

#include <cstdio>
#include <cstring>
#include <iostream>
#include <cmath>
#include <algorithm>
#include <queue>
#include <vector>
#include <utility>
using namespace std;

const int maxn = 1055000;
char a[maxn];
int len;

bool Judge(int n)
{
    for(int i=1;i<=n;i++){
        if(a[i] != a[len-n+i]) return false;
    }
    for(int i=n+1; i<=len-n; i++)
    {
        if(len-n-i+1<n) return false;
        bool flag = true;
        for(int j=1;j<=n;j++){
            if(a[j] != a[i+j-1]){
                flag = false;
                break;
            }
        }
        if(flag) return true;
    }
}


int main()
{
    freopen("E:\\acm\\input.txt","r",stdin);
    int T;
    cin>>T;
    while(T--)
    {
        scanf("%s",a+1);
        len = strlen(a+1);


        int l = 0;
        int r = len/3;
        int mid;
        while(l < r)
        {
            mid =l + (r - l + 1)/2;

            if(Judge(mid)) l = mid;
            else           r = mid - 1;
        }

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


}

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

#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <algorithm>
#include <iostream>
using namespace std;

const int maxn=20010;

int A[maxn], B[maxn], C[maxn];
int ans;

int gcd (int a, int b)
{
    return b==0?a:gcd(b, a%b);
}

void GetAns (int a, int b, int c)
{
    for(int i=0; i<31; i++){
        int x=1<<i;
        if()
    }
}

bool check (int a, int b, int c)
{
    if(ans<a || ans>b) return false;
    if((ans-a)*c==0) return true;
    return false;
}

int main()
{
    int n, m;
    
    while(scanf("%d", &n)==1){
        ans=0;
        for(int i=0; i<n; i++){
            scanf("%d %d %d", &A[i], &B[i], &C[i]);
            B[i]=(B[i]-A[i])/C[i]*C[i]+A[i];
            GetAns(A[i], B[i], C[i]);
        }
        
        if(!ans) printf("DC Qiang is unhappy.\n");
        else{
            m=0;
            for(int i=0; i<n; i++){
                if(check(A[i], B[i], C[i])) m++;
            }
            printf("%d\n", m);
        }
    }
    
    return 0;
}

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

2345 3
7 8 9
100 1
0
123 4 
1 2 3 4
934 4
1 2 3 4
567 4
5 6 7 1
789 4
1 2 3 9
890 3
1 2 0
890 4
1 2 3 9
890 4
1 2 3 8
110 9 
1 2 3 4 5 6 7 8 9
125 1
0
125 1
5
125 2
0 5
122 5
0 2 4 6 8
124 5
0 2 4 6 8
128 5
0 2 4 6 8
124 4
2 4 6 8
102 4
2 4 6 8
201 4
2 4 6 8

Case 1: 2345
Case 2: -1
Case 3: 5658
Case 4: 57908
Case 5: 3402
Case 6: 56808
Case 7: -1
Case 8: 4450
Case 9: 4450
Case 10: -1
Case 11: 125
Case 12: 1000
Case 13: -1
Case 14: -1
Case 15: -1
Case 16: -1
Case 17: 3100
Case 18: 510
Case 19: 1005

Compiler output:
main.c:1:1: error: expected identifier or '(' before numeric constant
    1 | 2345 3
      | ^~~~
Language: C

#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <iostream>
#include <algorithm>
using namespace std;

const long long zero=(long long)0;
const long long one=(long long)1;
const long long maxn=(long long)1<<32;
long long n, m, x, y, X, Y;

long long getlastz (long long x)
{
    long long s=0, i=1;
    while(!(i&x)){
        s++;
        i<<=1;
    }
    //printf("x %lld s %lld\n", x, s);
    return s;
}

long long getsum (long long x)
{
    long long s=0;
    while(x>zero){
        s+=getlastz(x);
        //printf("s %lld x %lld\n", s, x);
        x-=x&-x;
    }
    return s;
}

int main()
{
    while(scanf("%lld %lld", &n, &m)==2){
        long long L, R, M, tmp;

        L=1; R=maxn;
        while(L<R){
            M=L+(R-L)/2;
            x=getsum(M);
            if(x>=n) R=M;
            else L=M+1;
        }
        x=getsum(R);
        X=R;

        L=1; R=maxn;
        while(L<R){
            M=L+(R-L)/2;
            y=getsum(M);
            if(y>=m) R=M;
            else L=M+1;
        }
        y=getsum(R);
        Y=R;

        printf("x %lld y %lld X %lld Y %lld\n", x, y, X, Y);

        long long sum=0;
        for(int i=1; i<=31; i++){
            tmp=one<<i;

            L=X/tmp+1;
            if(L%2==0) L++;

            if(Y%tmp==0) R=Y/tmp-1;
            else R=Y/tmp;
            if(R%2==0) R--;

            if(L>R) continue;
            sum+=((R-L)/2+1)*(L+R)/2*tmp*i;

            printf("i %d L %lld R %lld\n", i, L, R);
        }

        if(n!=m) sum+=(x-n+1)*X+(y-m+1)*Y;
        else sum+=(x-n+1)*X;

        printf("%lld\n", sum);
    }

    return 0;
}

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

#include <iostream>
#include <cstdio>
#include <cstring>
#include <cmath>
using namespace std;
const double eps=1e-10;
const int maxn=30010;
int dcmp(double x)
{
    if(fabs(x)<eps) return 0;
    else return x<0?-1:1;
}
struct point
{
    double x,y;
    point(double x=0,double y=0):x(x),y(y){}
};
double a,b;
int main()
{
    while(scanf("%lf%lf",&a,&b)!=EOF)
    {

    }
    return 0;
}

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

#include <iostream>
#include <cstdio>
#include <cstring>
#include <cmath>
using namespace std;
typedef double matrix[70][300];
const double eps=1e-6;
int l,w,h;
int m,n;
int val[100];
bool gauss(matrix a)
{
    int i=0,j=0,k,r,u;
    while(i<m && j<n)
    {
        r=i;
        for(k=i+1;k<m;k++)
            if(fabs(a[k][j])>fabs(a[r][j])) r=k;
        if(fabs(a[r][j])>eps)
        {
            if(r!=i) for(k=0;k<=n;k++) swap(a[r][k],a[i][k]);
            for(k=n;k>=i;k--)
            {
                for(u=i+1;u<m;u++)
                    a[u][k]-=a[u][i]*a[i][k]/a[i][j];
            }
            i++;
        }
        j++;
//        for(k=0;k<m;k++)
//        {
//            for(u=0;u<=n;u++) cout<<a[k][u]<<" ";
//            cout<<endl;
//        }
    }
    int flag=1;
    for(k=i;k<m;k++) if(fabs(a[k][n])>eps) flag=0;
    for(k=0;k<i;k++) if(fabs(a[k][n]-ceil(a[k][n]))>eps) flag=0;
    if(flag==0) return false;
    else return i<=n;
}
int main()
{
    freopen("data","r",stdin);
    while(scanf("%d%d%d",&l,&w,&h)!=EOF)
    {
        n=0;m=l*w*h;
        matrix a;
        for(int i=0;i<m;i++)
            for(int j=0;j<=3*m;j++) a[i][j]=0;
        int u,v;
        for(int i=0;i<l;i++)
            for(int j=0;j<w;j++)
                for(int k=0;k<h;k++)
                {
                    u=i*w*h+j*h+k;
                    scanf("%d",&val[u]);
                    if(i+1<l)
                    {
                        v=(i+1)*w*h+j*h+k;
                        a[u][n]=1;a[v][n]=1;
                        n++;
                    }
                    if(j+1<w)
                    {
                        v=i*w*h+(j+1)*h+k;
                        a[u][n]=1;a[v][n]=1;
                        n++;
                    }
                    if(k+1<h)
                    {
                        v=i*w*h+j*h+k+1;
                        a[u][n]=1;a[v][n]=1;
                        n++;
                    }
                }
        for(int i=0;i<m;i++) a[i][n]=val[i];
//        for(int i=0;i<m;i++)
//        {
//            for(int j=0;j<=n;j++) cout<<a[i][j]<<" ";
//            cout<<endl;
//        }
//        cout<<endl;
        if(!gauss(a)) puts("No");
        else puts("Yes");
    }
    return 0;
}

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

#include<stdio.h>
int main(void)
{
    int ma=1;

   while(ma<=10){
       printf("%d*%d=%d\n",ma,ma,ma*ma);
       ma++;
  
 return(0);
}

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

#include<stdio.h>
int main(void){
int ma=1;

while(ma<=10){
printf("%d*%d=%d\n"ma,ma,ma*ma);
ma++;
}
return(0);
}

Compiler output:
main.c: In function 'main':
main.c:6:20: error: expected ')' before 'ma'
    6 | printf("%d*%d=%d\n"ma,ma,ma*ma);
      |       ~            ^~
      |                    )
Language: C

#include<stdio.h>
int main()
{
   int ma=1;

   while(ma<=10){
   printf("%d×%d=%d\n",ma,ma,ma*ma);
   ma++;
   }
return0;
}

Compiler output:
main.c: In function 'main':
main.c:10:1: error: 'return0' undeclared (first use in this function)
   10 | return0;
      | ^~~~~~~
main.c:10:1: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<cstdio>
#include<cstring>
#include<iostream>
#include<cmath>
#include<algorithm>
using namespace std;

char a[300], b[520000], c[520000];
int l1, l2;

int judge(int ip) {
	if(ip - l1 + 1 < 0) return 0;
	for(int i=ip-l1+1; i<=ip; i++) {
		if(c[i] != a[i-ip+l1-1]) return 0;
	}
	return 1;
}

int main() {
	int i, j, ip, ans;
	while(~scanf("%s", a)) {
		scanf("%s", b);
		l1 = strlen(a);
		l2 = strlen(b);
		ip = ans = 0;
		for(i=0; i<l2; i++) {
			c[ip] = b[i];
			if(judge(ip)) {
				ip -= l1;
				ans++;
			}
			ip++;
		}
		printf("%d\n", ans);
	}
	return 0;
}

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

#include<stdio.h>

int main(){
    int i,j,s
    for(i = 1,i <= 9,i++){
        for(j = 1,j <= 9,j++){
            s=i*j;
            printf("%dx%d=%d",i,j,s);
        }
    }
    
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
    5 |     for(i = 1,i <= 9,i++){
      |     ^~~
Language: C

#include<stdio.h>

int main(void){
    int i,j,s
    for(i = 1,i <= 9,i++){
        for(j = 1,j <= 9,j++){
            s=i*j;
            printf("%dx%d=%d",i,j,s);
        }
    }
    
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
    5 |     for(i = 1,i <= 9,i++){
      |     ^~~
Language: C

#include<stdio.h>

int main(void){
    int i,j,s
    for(i = 1,i <= 9,i++){
        for(j = 1,j <= 9,j++){
            s=i*j;
            printf("%dx%d=%d\n",i,j,s);
        }
    }
    
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
    5 |     for(i = 1,i <= 9,i++){
      |     ^~~
Language: C

#include <iostream>
using namespace std;
int main(){

	for (int i = 1; i <= 9; i++)
	{
		for (int j = 1; j <= 9 ; j++)
			cout<<i<<" * "<<j<<" = "
				<<i*j<<endl;
	}
	return 0;
}

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

#include <iostream>

using namespace std;

int main()
{
    while(!-1){
        long long int a,b;
        cin >> a >> b;
        cout << (a+b) << endl;
    }
    return 0;
}

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

#include <stdio.h>
#include <string.h>
#include <algorithm>
#include <iostream>
using namespace std;
#define N 27
int T,n;
char s[100];
int map[N][N],fg,f[N],mlen,st[100],stt[100],pre[100],pree[100],dep,edd,ed;
int q[100],cp;
void init()
{
    for(int i=0;i<26;i++)
    for(int j=0;j<26;j++)map[i][j]=1;
    memset(f,0,sizeof(f));
    mlen=0;
}
void dfs(int s,int h,int x)
{
    if(fg>0)return;
    if(s==x)
    {
        fg=h;
        return;
    }
    if(f[s])return;
    f[s]=1;

    for(int i=0;i<26;i++)
    {
        if(map[s][i])
        {
            st[h]=i;
            dfs(i,h+1,x);
        }
    }
}
void dfs1(int s,int x,int d)
{
    if(d>depp)
    {
        depp=d;
        edd=s;
    }
    for(int i=0;i<26;i++)
    {
        if(map[s][i])
        {
            pree[s]=x;
            dfs1(i,s,d+1);
        }
    }
}
void pt(int len,int st[],int fg)
{
    int ps=0;
    for(int i=0;i<len;i++)
    {
        int pos=ps+i;
        for(int j=0;j<len;j++)
        {
            printf("%c",st[pos]);
            pos++;
            if(pos>=fg)pos=0;
        }
        puts("");
    }
}
int main()
{
    scanf("%d",&T);
    while(T--)
    {
        scanf("%d",&n);
        init();
        for(int i=0;i<n;i++)
        {
            scanf("%s",s);
            map[s[0]-'a'][s[1]-'a']=0;
        }

        fg=-1;
        for(int i=0;i<26;i++)
        {
            if(map[i][i]==1)
            {
                fg=i;
                break;
            }
        }

        if(~fg)
        {
            for(int i=0;i<20;i++)
            {
                for(int j=0;j<20;j++)
                printf("%c",fg+'a');
                puts("");
            }
        }
        else
        {
            int dep_max=0;
            for(int i=0;i<26;i++)
            {
                memset(f,0,sizeof(f));
                dfs(i,0,i);
                if(fg)break;
            }
            if(fg)
            {
                pt(20,st,fg);

            }
            else
            {
                dep=0; depp=0;
                for(int i=0;i<26;i++)
                {
                    dfs1(i,-1);
                    if(depp>dep)
                    {
                        dep=depp;
                        ed=edd;
                        while(~pree[edd])
                        {
                            pre[edd]=pree[edd];
                            edd=pre[edd];
                        }
                    }
                }

                cp=0;

                while(~pre[ed])
                {
                    q[cp++]=ed;
                    ed=pre[ed];
                }

                reverse(q,q+cp);
                pt(dep-2, q, cp);
            }
        }
    }
    return 0;
}

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

#include <stdio.h>

int main(void)
{
  int i, j;

  for(i = 1; i <= 9; i++){
    for(j = 1; j <= 9; j++){
      printf("%dx%d=%d\n", i, j, i*j);
    }
  }

  return(0);

Compiler output:
main.c: In function 'main':
main.c:13:3: error: expected declaration or statement at end of input
   13 |   return(0);
      |   ^~~~~~
Language: C

#include <stdio.h>

int main(void)
{
  int i, j;

  for(i = 1; i <= 9; i++){
    for(j = 1; j <= 9; j++){
      printf("%dx%d=%d\n", i, j, i*j);
    }
  }

  return 0;

Compiler output:
main.c: In function 'main':
main.c:13:3: error: expected declaration or statement at end of input
   13 |   return 0;
      |   ^~~~~~
Language: C

#include<stdio.h>

int main(){
for(i=1;i<=9;i++){
for(j=1;j<=9;j++){
printf("%d"+"x"+"%d"+"="+"%d\n",i,j,i*j);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:5: error: 'i' undeclared (first use in this function)
    4 | for(i=1;i<=9;i++){
      |     ^
main.c:4:5: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:5: error: 'j' undeclared (first use in this function)
    5 | for(j=1;j<=9;j++){
      |     ^
main.c:6:12: error: invalid operands to binary + (have 'char *' and 'char *')
    6 | printf("%d"+"x"+"%d"+"="+"%d\n",i,j,i*j);
      |        ~~~~^
      |        |   |
      |        |   char *
      |        char *
main.c:8:1: error: expected declaration or statement at end of input
    8 | }
      | ^
main.c:8:1: error: expected declaration or statement at end of input
Language: C

#include<stdio.h>

int main(){
for(i=1;i<=9;i++){
for(j=1;j<=9;j++){
printf("%d",i);
printf("x");
printf("%d",j);
printf("=");
printf("%d\n",i*j);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:5: error: 'i' undeclared (first use in this function)
    4 | for(i=1;i<=9;i++){
      |     ^
main.c:4:5: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:5: error: 'j' undeclared (first use in this function)
    5 | for(j=1;j<=9;j++){
      |     ^
main.c:12:1: error: expected declaration or statement at end of input
   12 | }
      | ^
main.c:12:1: error: expected declaration or statement at end of input
Language: C

#include<stdio.h>

int main(){
    int i,j;
    for(i = 1;i<=9;i++){
        for(j = 1; j<=9;j++){
			pritnf("%dx%d=%d",j,i,j*i);
		}
    }

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:25: error: implicit declaration of function 'pritnf'; did you mean 'printf'? [-Wimplicit-function-declaration]
    7 |                         pritnf("%dx%d=%d",j,i,j*i);
      |                         ^~~~~~
      |                         printf
Language: C

#include int main(int argc, const char * argv[]) { int i, j; for (i = 1; i <= 9; i++) { for (j = 1; j <= 9; j++) { printf("%dx%d=%d\n", i, j, i * j); } } return 0; }

Compiler output:
main.c:1:10: error: #include expects "FILENAME" or <FILENAME>
    1 | #include int main(int argc, const char * argv[]) { int i, j; for (i = 1; i <= 9; i++) { for (j = 1; j <= 9; j++) { printf("%dx%d=%d\n", i, j, i * j); } } return 0; }
      |          ^~~
Language: C

#include<stdio.h>

int main(){
    int i = 9;
     int j=0;
    for(;i<=9;i++)
{
    j=i*i;
    printf("%d*%d=%d"i,i,j);
    return 0;
}
}

Compiler output:
main.c: In function 'main':
main.c:9:22: error: expected ')' before 'i'
    9 |     printf("%d*%d=%d"i,i,j);
      |           ~          ^
      |                      )
Language: C

#include <cstdio>
using namespace std;
int main()
{
	int i,j;
	for(i=1;i<10;i++)
		for(j=1;j<10;j++)
			printf("%dx%d=%d\n",i,j,i*j);
	getchar();
	return 0;
}

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

#include <stdio.h>
#include <string.h>

#define maxx(a,b) a>b?a:b

const int N = 1000000010;
int m[N];
int l[N];
int r[N];

int main()
{
	int n;
	while(scanf("%d",&n)!=EOF,n)
	{
		int i,j;
		for(i=1;i<=n;i++)
		{
			scanf("%d",&m[i]);
		}
		memset(l,0,sizeof(l));
		memset(r,0,sizeof(r));
		for(i=1;i<=n;i++)
		{
			while(m[l[i]-1]>=m[i])
			{
              l[i]=l[l[i]-1];
			}
		}
		for(i=n;i>=1;i--)
		{
			while(m[r[i]+1]>=m[i])
			{
				
			}
		}
	}
	return 0;
}

Compiler output:
main.c:7:5: error: variably modified 'm' at file scope
    7 | int m[N];
      |     ^
main.c:8:5: error: variably modified 'l' at file scope
    8 | int l[N];
      |     ^
main.c:9:5: error: variably modified 'r' at file scope
    9 | int r[N];
      |     ^
Language: C

#include<stdio.h> int main() {int i,j; for(i=1;i<=9;++i) { for(j=1;j<=9;++j) { printf("%d * %d = %d\n",i,j,i*j); } } return 0; }

Compiler output:
main.c:1:19: warning: extra tokens at end of #include directive
    1 | #include<stdio.h> int main() {int i,j; for(i=1;i<=9;++i) { for(j=1;j<=9;++j) { printf("%d * %d = %d\n",i,j,i*j); } } return 0; }
      |                   ^~~
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include<stdio.h>
int main(void){
  int i, j;
  for(i=1;i<=9;i++){
    for(j=1;j<=9;j++){
      printf("%d %s %d %s %d",i,x,j,=,i*j);
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:33: error: 'x' undeclared (first use in this function)
    6 |       printf("%d %s %d %s %d",i,x,j,=,i*j);
      |                                 ^
main.c:6:33: note: each undeclared identifier is reported only once for each function it appears in
main.c:6:37: error: expected expression before '=' token
    6 |       printf("%d %s %d %s %d",i,x,j,=,i*j);
      |                                     ^
Language: C

#include <cstdio>
#include <cstring>
#include <algorithm>
using namespace std;
const int N = 1005;
int dp[N][8];
int a[N][5];
int x;
bool ok(int st, int x) {
        return !(st>>x&1);
}
int fix(int st, int x) {
        return st|(1<<x);
}
void dfs(int y, int pre, int now, int val) {
        if(y == 3) {
                dp[x+1][now] = max(dp[x+1][now], val);
                return;
        }
        int i, j;
        dfs(y+1, pre, now, val); // no
        if(ok(pre, y) && ok(now, y)) { //*
                                       //*
                dfs(y+1, fix(pre, y), fix(now, y), val+a[x][y]*a[x+1][y]);
        }
        if(y+1 < 3 && ok(now, y) && ok(now, y+1)) { //**
                dfs(y+1, fix(now, y), fix(now, y+1), val+a[x+1][y]*a[x+1][y+1]);
        }
}
int n;
int main() {
        int i, j, ca = 1;
        while(~scanf("%d", &n) && n) {
                for(i = 0; i <= n; i++)
                        for(j = 0; j < 8; j++)
                                dp[i][j] = -1e9;
                for(i = 1; i <= 3; i++)
                        for(j = 1; j <= n; j++)
                                scanf("%d", &a[j][i]);
                dp[0][7] = 0;
                for(i = 0; i <= n; i++) {
                        for(j = 0; j < 8; j++) if(dp[i][j] != -1e9){
                                x = i;
                                dfs(0, j, 0, dp[i][j]);
                        }
                }
                int ans  = 0;
                for(i = 0; i < 8; i++)
                        ans = max(ans, dp[n+1][i]);
                printf("Case %d: %d\n", ca++, ans);
        }
        return 0;
}
/*
4
7 2 4 9
3 5 9 3
9 5 1 8

*/

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

#include <cstdio>
#include <cstring>
#include <algorithm>
using namespace std;
const int N = 1005;
int dp[N][8];
int a[N][5];
int x;
bool ok(int st, int x) {
        return !(st>>x&1);
}
int fix(int st, int x) {
        return st|(1<<x);
}
void dfs(int y, int pre, int now, int val) {
        if(y == 3) {
                dp[x+1][now] = max(dp[x+1][now], val);
              //  printf ( "dp[%d][%d] = %d\n" , x +1 , now , dp[x+1][now] ) ;
                return;
        }
        int i, j;
        dfs(y+1, pre, now, val); // no
        if(ok(pre, y)) { //*
                                       //*
                dfs(y+1, fix(pre, y), fix(now, y), val+a[x][y]*a[x+1][y]);
        }
        if(y+1 < 3 && ok(pre, y) && ok (pre , y + 1) ) { //**
                dfs(y+2, fix(fix(pre, y),y+1),now, val+a[x][y]*a[x][y+1]);
        }
}
int n;
int main() {
        int i, j, ca = 1;
        while(~scanf("%d", &n) && n) {
                for(i = 0; i <= n; i++)
                        for(j = 0; j < 8; j++)
                                dp[i][j] = 0;
                for(i = 1; i <= n; i++)
                        for(j = 0; j < 3; j++)
                                scanf("%d", &a[i][j]);
                for(i = 0; i <= n; i++) {
                        for(j = 0; j < 8; j++) {
                                x = i;
                          //      printf ( "i = %d , j = %d\n" , i , j ) ;
                                dfs(0, j, 0, dp[i][j]);
                        }
                }
                int ans  = 0;
                printf("Case %d: %d\n", ca++, dp[n+1][0]);
        }
        return 0;
}
/*
4
7 2 4 9
3 5 9 3
9 5 1 8

*/

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

#include <cstdio>
#include <cstring>
#include <algorithm>
#include <iostream>
#include <vector>
#include <map>
#include <string>
using namespace std;
const int N = 66;
typedef unsigned long long ll;
ll n, m, f[N], cnt[N][4];
void init() {
        ll p = 2;
        f[0] = 1;f[1] = 1;
        for(int i = 2; i < N; i++) {
                p <<=1;
                f[i] = p-f[i-1];
                cnt[i][3] = f[i-2];
                cnt[i][1] = cnt[i][0] = (f[i]-cnt[i][3])>>1;
                cnt[i][2] =cnt[i][1]>>1;
                cnt[i][1] -= cnt[i][2];
        }
        cnt[1][0] = 1;
}
void dfs(ll x, int len, string &s) {
        if(!len) {
                cout <<s;
                return;
        }
        if(x==1) {
                for(int i = 0; i < len; i++)
                        s += 'a';
                cout<<s;
                return;
        }
        if(x <= cnt[len][0]) {
                s += "a";
                dfs(x, len-1, s);
        }
        else if(x <= cnt[len][0]+cnt[len][1]) {
                s += "ab";
                dfs(x-cnt[len][0], len-2, s);
        }
        else if(x <= cnt[len][0]+cnt[len][1]+cnt[len][2]){
                s += "abb";
                dfs(x-cnt[len][0]-cnt[len][1], len-3, s);
        }else {
                s += "bb";
                dfs(x-cnt[len][0]-cnt[len][1]-cnt[len][2], len-2, s);
        }
}
void gao(ll a, ll b) {
        a = a*n+b;
        int i;
        string s="";
        for(i = 1; i < N; i++)
                if(a > f[i]) a -= f[i];
                else break;
        dfs(a, i, s);
}
int main() {
        init();
        int i, j, ca=1;
        while(cin>>n>>m) {
                if(!n && !m) break;
                cout<<"Case " << ca <<": ";
                gao(m-1, 1); cout<<" ";
                gao(m, 0); cout<<"\n";
        }
        return 0;
}

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

49  46  45  28  27  26  25
48  47  44  29  32  33  24
5   6   43  30  31  34  23
4   7   42  41  40  35  22
3   8   13  14  39  36  21
2   9   12  15  38  37  20
1   10  11  16  17  18  19

Compiler output:
main.c:1:1: error: expected identifier or '(' before numeric constant
    1 | 49  46  45  28  27  26  25
      | ^~
Language: C

#include <stdio.h>
int main()
{
	__int64 i,j;
	for(i=1;i<=9;i++)
	{
		for(j=1;j<=9;j++)
			printf("%I64d*%I64d=%I64d\n",i,j,i*j);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:9: error: unknown type name '__int64'; did you mean '__int64_t'?
    4 |         __int64 i,j;
      |         ^~~~~~~
      |         __int64_t
Language: C

#include <cstdio>
#include <cstring>
#include <algorithm>
#include <cmath>
using namespace std;
typedef long long ll;
const double eps = 1e-8;
struct Point {
    double x, y;
    Point operator-(const Point &t) const {
        return (Point) {x-t.x, y-t.y};
    }
}p[100005];
int n, m, k;
int cross(Point o, Point a, Point b) {
    double t = (a.x-o.x)*(b.y-o.y)-(a.y-o.y)*(b.x-o.x);
    if(fabs(t) < eps) return 0;
    return t > 0 ? 1 : -1;
}
bool bin(Point &tp) {
    int l = 0, r = n-1;
    while(l < r) {
        int m = l+r >> 1;
     //   int c1 = cross(tp, p[0], p[m]);
//        int c2 = cross(tp, p[0], p[(m+1)%n]);
//        int c3 = cross(tp, p[m], p[(m+1)%n]);
        int c1 = cross(p[0], p[m], tp);
        int c2 = cross(p[0], p[(m+1)%n], tp);
        int c3 = cross(p[m], p[(m+1)%n], tp);
        if(c1 >= 0 && c2 <= 0) {
        	if(c3 <= 0)return true;
            else return false;
        }
        if(c1 > 0)
            l = m+1;
        else r = m;
    }
    Point a = p[l], b = p[(l+1)%n];
    return cross(a, b, tp) ==0 && (tp.x-a.x)*(tp.x-b.x) <=0 && (tp.y-a.y)*(tp.y-b.y) <=0;
}
int main() {
    int i;
    while(~scanf("%d", &n)) {
        for(i = n-1; i >=0; i--) {
            getchar();
            scanf("(%lf,%lf)", &p[i].x, &p[i].y);
        }
        int cnt = 0;
        p[n] = p[0];
        scanf("%d", &m);
        while(m--) {
            Point tp;
            getchar();
            scanf("(%lf,%lf)", &tp.x, &tp.y);
            puts(bin(tp)? "Yes" : "No");
        }
    }
    return 0;
}

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

#include<stdio.h>
int main(){
int i,j;
for(i=1;i<=9;i++){
 for(j=1;j<=9;j++){
  printf("%d"+"x"+"%d"+"="+"%d",i,j,i*j);
 }
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:14: error: invalid operands to binary + (have 'char *' and 'char *')
    6 |   printf("%d"+"x"+"%d"+"="+"%d",i,j,i*j);
      |          ~~~~^
      |          |   |
      |          |   char *
      |          char *
Language: C

#include <iostream>
#include<stdio.h>
using namespace std;

int main(){
 while(1){
    int i,j;
    for(i=1;i<=9;i++){
        for(j=1;j<=9;j++){
            printf("%d*%d=%d\n",i,j,i*j);
        }
    }
}
    return 0;
}

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

include<stdio.h>

int main()
{
int i,j;
for(i=1;i<=9;i++)
for(j=1;j<=9;j++)
printf("%dx%d=%d",i,j,i*j);
return 0;
}

Compiler output:
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include<stdio.h>
      |        ^
Language: C










#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <string>
#include <cmath>
#include <vector>
using namespace std;

#define LL long long
#define eps 1e-8
#define mod 1000000007

struct node{
    int a ,d ,b ;
}a[30];
int u[30] ;
void init(){
    int n = 30 ;
    for( int i = 0 ;i < n ;i ++ ){
        if( i & 1 ) u[i] = 1 ;
        else u[i] = -1 ;
    }
}
long long gcd( long long a ,long long b ){
    return b == 0 ? a : gcd( b ,a % b ) ;
}
long long lcm( long long a ,long long b ){
    return a * b / gcd( a ,b ) ;
}
void exgcd( int a ,int b ,long long &x ,long long &y ,int c ){
    if( !b ){
        y = 0 ,x = c / a ;
        return ;
    }
    exgcd( b ,a%b ,y ,x ,c ) ;
    y -= a/b * x ;
}
bool uni( node a ,node b ,node &ret ){
    if( b.d == 0 && a.d == 0 ){
        ret = a ;
        ret.b = min( a.b ,b.b ) ;
        if( b.a != a.a ) return 0 ;
        return 1 ;
    }
    if( b.d == 0 ){
        if( ( b.a % a.d + a.d ) % a.d != ( a.a % a.d + a.d ) % a.d ) //
            return 0 ;
        ret.d = b.d ;
        ret.b = min( a.b ,b.b ) ;
        ret.a = b.a ;
        return 1 ;
    }
    if( a.d == 0 ){
        if( ( a.a % b.d + b.d ) % b.d != ( b.a % b.d + b.d ) % b.d ) //
            return 0 ;
        ret.d = a.d ;
        ret.b = min( a.b ,b.b ) ;
        ret.a = a.a ;
        return 1 ;
    }
    ret.b = min( a.b ,b.b ) ;
    long long x1 ,y1 ,x2 ,y2 ;
    long long d = a.d / gcd( a.d ,b.d ) ;
    exgcd( d ,b.d ,x1 ,y1 ,b.a ) ;
    exgcd( b.d ,d ,x2 ,y2 ,a.a%d ) ;
    long long L = lcm( a.d ,b.d ) ;
    if( L > 2147483647LL ) return 0 ;
    long long u = ( x1 * d + x2 * b.d ) % L ;
    if( u < 0 ) u += L ;
    if( ( u % d + d ) % d != ( a.a % d + a.d ) % d || ( u % b.d + b.d ) % b.d != ( b.a % b.d + b.d ) % b.d ) return 0 ; //
    int k = ( max( a.a ,b.a ) - u ) / L ;
    u += k * L ;
    ret.a = u ,ret.d = L ;
    return 1 ;
}
int cal( node tmp ){ 
    if( tmp.d == 0 ){
        if( tmp.b >= tmp.a ) return 1 ;
        return 0 ;
    }
    if( tmp.b < tmp.a ) return 0 ;
    return ( tmp.b - tmp.a ) / tmp.d + 1 ;
}
void solve( int n ){
    int ans = 0 ;
    for( int i = 1 ;i < (1<<n) ;i ++ ){
        node tmp ;bool flag = 1 ;
        int cnt = 0 ;
        int j ;
        int tans = 0 ;
        for( j = 0 ;j < n ;j ++ )
            if( (1<<j) & i ){
                cnt = 1 ;
                tmp = a[j] ;
          //      tans += cal( a[j] ) ;
                break ;
            }
        for( j = j + 1;j < n ;j ++ ) if( (1<<j) & i ){
            cnt ++ ;
            if( !uni( tmp ,a[j] ,tmp ) ){ flag = 0 ;break ;}
         //   tans += cal( tmp ) ;
        }
        tans = cal( tmp ) ;
        if( flag ) ans += tans * u[cnt] ;
    }
    cout << ans << endl ;
}
int main(){
    int n ;
    init() ;
    while( scanf( "%d" ,&n ) && n ){
        for( int i = 0 ;i < n ;i ++ ){
            scanf( "%d %d %d" ,&a[i].a ,&a[i].b ,&a[i].d ) ;
        }
        solve( n ) ;
    }
}

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

#include<stdio.h>

int main(){
　　int i, j;

    for(i=1; i<10; i++)
      for(j=1; j<10; j++)
        printf("%dx%d=%d\n", i, j, i*j);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:1: error: stray '\343' in program
    4 | <U+3000><U+3000>int i, j;
      | ^~~~~~~~
main.c:4:3: error: stray '\343' in program
    4 | <U+3000><U+3000>int i, j;
      |         ^~~~~~~~
Language: C

	int i=1,j=1;
	for(i=1;i<10;i++){
		for(j=1;j<10;j++){
			printf("%d×%d=%d\n",i,j,i*j);
		}
	}

Compiler output:
main.c:2:9: error: expected identifier or '(' before 'for'
    2 |         for(i=1;i<10;i++){
      |         ^~~
main.c:2:18: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    2 |         for(i=1;i<10;i++){
      |                  ^
main.c:2:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
    2 |         for(i=1;i<10;i++){
      |                       ^~
Language: C

#include <map>
#include <set>
#include <queue>
#include <ctime>
#include <cmath>
#include <string>
#include <cstdio>
#include <vector>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <algorithm>
using namespace std;

#define all(a) a.begin(),a.end()
#define clr(a) memset(a,0,sizeof(a))
#define fill(a,b) memset(a,b,sizeof(a))
#define pb push_back
#define mp make_pair

typedef long long LL;
typedef vector<int> VI;
typedef pair<int,int> PII;
typedef vector<pair<int,int> > VII;

const double eps = 1e-8;
const double pi = acos(-1.0);
char str[200007];
int s[200007];
bool check(int len)
{
	bool ok=true;
	if (len%2==0)
	{
		for (int i=0;i<len;i++)
			if (s[i]!=0)
			{
				ok=false;
				break;
			}
		return ok;
	}
	else
	{
		for (int i=0;i<len;i+=2)
			if (s[i]!=0)
			{
				ok=false;
				break;
			}
		if (ok)
		{
			for (int i=1;i<len;i+=2)
				s[i/2]=s[i];
			return check(len/2);
		}
		else
		{
			ok=true;
			for (int i=1;i<len;i+=2)
				if (s[i]!=0)
				{
					ok=false;
					break;
				}
			if (ok)
			{
				for (int i=0;i<len-2;i+=2)
				{
					s[i/2]=s[i]^s[i+2];
					return check(len/2);
				}
			}
			else
				return false;
		}
	}
}

int main(){
	scanf("%d",&n);
	getchar();
	while (n--)
	{
		scanf("%s",str);
		int len=strlen(str);
		for (int i=0;i<len;i++)
			s[i]=str[i]-'0';
		printf(check());
	}
    return 0;
}

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

#include<stdio.h>
#include<iostream>
#include<cstring>
#include<queue>
using namespace std;
#define LL long long
const int kind =26;
struct node
{
   node * fail;
   node *next[kind];
   int count,sz;
   node()
   {
		fail=NULL;
		sz=count =0;
		for(int i=0;i<kind;i++)
		next[i]=NULL;
	}
};

char keyword[3001000];
char str[1100];



void insert(node *root,char *word,int x)
{
	node *location=root;
	int i=0,branch=0;

	while(word[i])
	{
		branch=word[i]-'a';
		if(location->next[branch]==NULL)
		   location->next[branch]=new node();
		   i++;
		   location=location->next[branch];
	}
	location->sz=i;
	if(location->count==0) location->count=x;
	else location->count=min(location->count,x);

}

void buid_fail(node * root)
{
      queue<node *> q;
	  while(!q.empty())
	          q.pop();

	    root->fail=NULL;
	    int i=0;
		q.push(root);
		while(!q.empty())
		{
			node *temp=q.front();
			           q.pop();
			node *p=NULL;
			for(i=0;i<26;i++)
			    if(temp->next[i]!=NULL)
				{
					if(temp==root)
					      temp->next[i]->fail=root;
					else
					{
						p=temp->fail;
						while(p!=NULL)
						{
						     if(p->next[i]!=NULL)
							 {
								temp->next[i]->fail=p->next[i];
								break;
							 }
							p=p->fail;
						}
						if(p==NULL)
						   temp->next[i]->fail=root;
					}
					q.push(temp->next[i]);
				}

		}
}

LL dp[1009];

void AC_search(node * root,char * str)
{
	int i=0,index,len=strlen(str);
	node *p=root;
	i=0;
//	cout<<str<<" str"<<endl;
	while(str[i])
	{
//	    printf("%c\n",str[i]);
		index=str[i]-'a';
		while(p->next[index]==NULL && p!=root)
	                      p=p->fail;
	    p=p->next[index];
	    p=(p==NULL) ? root : p;

	    node *temp=p;
	    while(temp!=root)
	    {
			dp[i]=min(dp[i],temp->count + dp[i- temp->sz]);
			temp=temp->fail;
		}
//		puts("...............");
		i++;
	}
}
#define inf 10000000000000000LL
int main()
{
    freopen("1.in","r",stdin);
    freopen("k1.out","w",stdout);
    int T;
    scanf("%d",&T);
    while(T--)
    {
        gets(str);gets(str);
//        puts(str);
        node *root=new node();
        int n;
        scanf("%d",&n);
        for(int i=0;i<n;i++)
        {
            gets(keyword);
            int x;
            scanf("%s%d",keyword,&x);
//            puts(keyword);
            insert(root,keyword,x);
        }
//        puts("*********");
        buid_fail(root);
//        puts("+++++++++++");
        int m=strlen(str);
        for(int i=0;i<m;i++) dp[i]=inf;
//        puts("pppppppp");
        AC_search(root,str);
//        puts("========");
        if(dp[m-1]<inf) printf("%I64d\n",dp[m-1]);
        else puts("-1");
    }
    return 0;
}

/*
2
abcd
6
a 5
bc 10
cd 8
bcd 20
d 5
ab 7
ab
2
c 1
dd 1
*/

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