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

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cout >>a[0]>>a[1]>>a[2]>>a[3];
	cout >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high=asum;
	if (bsum>asum) high = bsum;
	
	cin<<high<<\n;

	return 0;
}

Compiler output:
a.cc:39:20: error: stray '\' in program
   39 |         cin<<high<<\n;
      |                    ^
a.cc:20:9: error: 'paair' does not name a type
   20 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:30:9: error: 'cout' was not declared in this scope
   30 |         cout >>a[0]>>a[1]>>a[2]>>a[3];
      |         ^~~~
a.cc:17:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   16 | #include<cstdio>
  +++ |+#include <iostream>
   17 | #include<vector>
a.cc:39:9: error: 'cin' was not declared in this scope
   39 |         cin<<high<<\n;
      |         ^~~
a.cc:39:9: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:39:21: error: 'n' was not declared in this scope
   39 |         cin<<high<<\n;
      |                     ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cout >>a[0]>>a[1]>>a[2]>>a[3];
	cout >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high=asum;
	if (bsum>asum) {high = bsum;}
	
	cin<<high<<\n;

	return 0;
}

Compiler output:
a.cc:39:20: error: stray '\' in program
   39 |         cin<<high<<\n;
      |                    ^
a.cc:20:9: error: 'paair' does not name a type
   20 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:30:9: error: 'cout' was not declared in this scope
   30 |         cout >>a[0]>>a[1]>>a[2]>>a[3];
      |         ^~~~
a.cc:17:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   16 | #include<cstdio>
  +++ |+#include <iostream>
   17 | #include<vector>
a.cc:39:9: error: 'cin' was not declared in this scope
   39 |         cin<<high<<\n;
      |         ^~~
a.cc:39:9: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:39:21: error: 'n' was not declared in this scope
   39 |         cin<<high<<\n;
      |                     ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cout >>a[0]>>a[1]>>a[2]>>a[3];
	cout >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high

	high=asum;
	if (bsum>asum) {high = bsum;}
	
	cin<<high<<\n;

	return 0;
}

Compiler output:
a.cc:41:20: error: stray '\' in program
   41 |         cin<<high<<\n;
      |                    ^
a.cc:20:9: error: 'paair' does not name a type
   20 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:30:9: error: 'cout' was not declared in this scope
   30 |         cout >>a[0]>>a[1]>>a[2]>>a[3];
      |         ^~~~
a.cc:17:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   16 | #include<cstdio>
  +++ |+#include <iostream>
   17 | #include<vector>
a.cc:38:9: error: expected initializer before 'high'
   38 |         high=asum;
      |         ^~~~
a.cc:39:25: error: 'high' was not declared in this scope
   39 |         if (bsum>asum) {high = bsum;}
      |                         ^~~~
a.cc:41:9: error: 'cin' was not declared in this scope
   41 |         cin<<high<<\n;
      |         ^~~
a.cc:41:9: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:41:14: error: 'high' was not declared in this scope
   41 |         cin<<high<<\n;
      |              ^~~~
a.cc:41:21: error: 'n' was not declared in this scope
   41 |         cin<<high<<\n;
      |                     ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cin >>a[0]>>a[1]>>a[2]>>a[3];
	cin >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high

	high=asum;
	if (bsum>asum) {high = bsum;}
	
	cout<<high<<\n;

	return 0;
}

Compiler output:
a.cc:41:21: error: stray '\' in program
   41 |         cout<<high<<\n;
      |                     ^
a.cc:20:9: error: 'paair' does not name a type
   20 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:30:9: error: 'cin' was not declared in this scope
   30 |         cin >>a[0]>>a[1]>>a[2]>>a[3];
      |         ^~~
a.cc:17:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   16 | #include<cstdio>
  +++ |+#include <iostream>
   17 | #include<vector>
a.cc:38:9: error: expected initializer before 'high'
   38 |         high=asum;
      |         ^~~~
a.cc:39:25: error: 'high' was not declared in this scope
   39 |         if (bsum>asum) {high = bsum;}
      |                         ^~~~
a.cc:41:9: error: 'cout' was not declared in this scope
   41 |         cout<<high<<\n;
      |         ^~~~
a.cc:41:9: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:41:15: error: 'high' was not declared in this scope
   41 |         cout<<high<<\n;
      |               ^~~~
a.cc:41:22: error: 'n' was not declared in this scope
   41 |         cout<<high<<\n;
      |                      ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cin >>a[0]>>a[1]>>a[2]>>a[3];
	cin >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high;

	high=asum;
	if (bsum>asum) {high = bsum;}
	
	cout<<high<<\n;

	return 0;
}

Compiler output:
a.cc:41:21: error: stray '\' in program
   41 |         cout<<high<<\n;
      |                     ^
a.cc:20:9: error: 'paair' does not name a type
   20 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:30:9: error: 'cin' was not declared in this scope
   30 |         cin >>a[0]>>a[1]>>a[2]>>a[3];
      |         ^~~
a.cc:17:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   16 | #include<cstdio>
  +++ |+#include <iostream>
   17 | #include<vector>
a.cc:41:9: error: 'cout' was not declared in this scope
   41 |         cout<<high<<\n;
      |         ^~~~
a.cc:41:9: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:41:22: error: 'n' was not declared in this scope
   41 |         cout<<high<<\n;
      |                      ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<iostream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef paair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cin >>a[0]>>a[1]>>a[2]>>a[3];
	cin >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high;

	high=asum;
	if (bsum>asum) {high = bsum;}
	
	cout<<high<<\n;

	return 0;
}

Compiler output:
a.cc:42:21: error: stray '\' in program
   42 |         cout<<high<<\n;
      |                     ^
a.cc:21:9: error: 'paair' does not name a type
   21 | typedef paair<int,int> P;
      |         ^~~~~
a.cc: In function 'int main()':
a.cc:42:22: error: 'n' was not declared in this scope
   42 |         cout<<high<<\n;
      |                      ^
Language: C++

/*
	AOJ 0510 JOI yo 2005 2006 1 Score
*/

//ミスを防ぐためにまずは基本のIncludeをすべて格納する

#include<fstream>
#include<iostream>
#include<string>
#include<queue>
#include<algorithm>
#include<set>
#include<map>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<cstdio>
#include<vector>
#define INF (1<<21)
using namespace std;
typedef pair<int,int> P;

//ここまで基本型、多少の変更はあるけどまあいける

int main()
{
	int a[4],b[4];
	int asum,bsum;


	cin >>a[0]>>a[1]>>a[2]>>a[3];
	cin >>b[0]>>b[1]>>b[2]>>b[3];

	asum=a[0]+a[1]+a[2]+a[3];
	bsum=b[0]+b[1]+b[2]+b[3];

	int high;

	high=asum;
	if (bsum>asum) {high = bsum;}
	
	cout<<high<<\n;

	return 0;
}

Compiler output:
a.cc:42:21: error: stray '\' in program
   42 |         cout<<high<<\n;
      |                     ^
a.cc: In function 'int main()':
a.cc:42:22: error: 'n' was not declared in this scope
   42 |         cout<<high<<\n;
      |                      ^
Language: C++

#include <cstdio>

int main()
{
int s = 0, t = 0, temp;
for(int i = 0; i < 4; ++i) {
scanf("%d", &temp);
s += temp;
}
for(int i = 0; i < 4; ++i) {
scanf("%d", &temp);
t += temp;
printf("%d\n", max(s, t));
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:16: error: 'max' was not declared in this scope
   13 | printf("%d\n", max(s, t));
      |                ^~~
a.cc:15:2: error: expected '}' at end of input
   15 | }
      |  ^
a.cc:4:1: note: to match this '{'
    4 | {
      | ^
Language: C++

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

int main(){int s = 0, t = 0, temp;for(int i = 0; i < 4; ++i) {scanf("%d", &temp);s += temp;}for(int i = 0; i < 4; ++i) {scanf("%d", &temp);t += temp;printf("%d\n", max(s, t));return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:186: error: expected '}' at end of input
    5 | int main(){int s = 0, t = 0, temp;for(int i = 0; i < 4; ++i) {scanf("%d", &temp);s += temp;}for(int i = 0; i < 4; ++i) {scanf("%d", &temp);t += temp;printf("%d\n", max(s, t));return 0;}
      |           ~                                                                                                                                                                              ^
Language: C++

#include<stdio.h>
#include<math.h>
int a,b,c;main(){for(;scanf("%d",&a);b+=a);for(;scanf("%d",&a);c+=a);printf("%d",max(b,c));}

Compiler output:
a.cc:3:11: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    3 | int a,b,c;main(){for(;scanf("%d",&a);b+=a);for(;scanf("%d",&a);c+=a);printf("%d",max(b,c));}
      |           ^~~~
a.cc: In function 'int main()':
a.cc:3:82: error: 'max' was not declared in this scope; did you mean 'std::max'?
    3 | int a,b,c;main(){for(;scanf("%d",&a);b+=a);for(;scanf("%d",&a);c+=a);printf("%d",max(b,c));}
      |                                                                                  ^~~
      |                                                                                  std::max
In file included from /usr/include/c++/14/bits/specfun.h:43,
                 from /usr/include/c++/14/cmath:3906,
                 from /usr/include/c++/14/math.h:36,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: 'std::max' declared here
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
Language: C++

#include <stdio.h>
a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}

Compiler output:
a.cc:2:1: error: 'a' does not name a type
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      | ^
a.cc:2:9: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |         ^~~~
a.cc: In function 'int main()':
a.cc:2:21: error: 'i' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                     ^
a.cc:2:41: error: 'a' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                         ^
a.cc:2:44: error: 'b' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                            ^
a.cc:2:68: error: 'a' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                                                    ^
a.cc:2:71: error: 'c' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                                                       ^
a.cc:2:91: error: 'b' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                                                                           ^
a.cc:2:93: error: 'c' was not declared in this scope
    2 | a,b,c,i;main(){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                                                                                             ^
Language: C++

#include <stdio.h>
main(a,b,c,i){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}

Compiler output:
a.cc:2:5: error: expected constructor, destructor, or type conversion before '(' token
    2 | main(a,b,c,i){for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |     ^
Language: C++

#include <stdio.h>
int a,b,c,i;main();{for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}

Compiler output:
a.cc:2:19: error: expected constructor, destructor, or type conversion before ';' token
    2 | int a,b,c,i;main();{for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                   ^
a.cc:2:20: error: expected unqualified-id before '{' token
    2 | int a,b,c,i;main();{for(;i<4;i++,scanf("%d",&a),b+=a);for(;~scanf("%d",&a);c+=a);printf("%d\n",b>c?b:c);}
      |                    ^
Language: C++

#include <iostream>
#include <fstream>
#include <vector>
#include <string>
#include <cstdlib>
#include <algorithm>
#include <conio.h>
using namespace std;

int main(){
	int tmp1,tmp2;
	int a=0,b=0;
	for(int i=0; i<4; ++i){
		cin >> tmp1;
		a += tmp1;	
	}
	for(int i=0; i,4; ++i){
		cin >> tmp2;
		b += tmp2;
	}
	if(a >= b){
		cout << a << endl;
	} else if(b > a){
		cout << b << endl;
	}

	return 0;
}

Compiler output:
a.cc:7:10: fatal error: conio.h: No such file or directory
    7 | #include <conio.h>
      |          ^~~~~~~~~
compilation terminated.
Language: C++

#include <studio.h>

int q,w,e,r,t,y,u,i;
scanf("%d%d%d%d",&q,&w,&e,&r);
scanf("%d%d%d%d",&t,&y,&u,&i);

printf("%d",(q+w+e+r>=t+y+u+i?q+w+e+r:t+y+u+i));

Compiler output:
a.cc:1:10: fatal error: studio.h: No such file or directory
    1 | #include <studio.h>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <studio.h>

int main(){
int q,w,e,r,t,y,u,i;
scanf("%d%d%d%d",&q,&w,&e,&r);
scanf("%d%d%d%d",&t,&y,&u,&i);

printf("%d",(q+w+e+r>=t+y+u+i?q+w+e+r:t+y+u+i));

return 0;
}

Compiler output:
a.cc:1:10: fatal error: studio.h: No such file or directory
    1 | #include <studio.h>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

/*#include <studio.h>

int main(){
int q,w,e,r,t,y,u,i;
scanf("%d%d%d%d",&q,&w,&e,&r);
scanf("%d%d%d%d",&t,&y,&u,&i);

printf("%d",(q+w+e+r>=t+y+u+i?q+w+e+r:t+y+u+i));

return 0;
}*/

#include <studio.h> int main() { printf("Hello!"); return 0; } 

Compiler output:
a.cc:13:21: warning: extra tokens at end of #include directive
   13 | #include <studio.h> int main() { printf("Hello!"); return 0; }
      |                     ^~~
a.cc:13:10: fatal error: studio.h: No such file or directory
   13 | #include <studio.h> int main() { printf("Hello!"); return 0; }
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <studio.h> int main() { printf("Hello!"); return 0; } 

Compiler output:
a.cc:1:21: warning: extra tokens at end of #include directive
    1 | #include <studio.h> int main() { printf("Hello!"); return 0; }
      |                     ^~~
a.cc:1:10: fatal error: studio.h: No such file or directory
    1 | #include <studio.h> int main() { printf("Hello!"); return 0; }
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

int main()
{
    int a, b, c, d;
    int sum = 0;
    std::cin >> a >> b >> c >> d;
    sum = a + b + c + d;  
    std::cin >> a >> b >> c >> d;
    if(sum < (a + b + c + d)){
        std::cout << (a + b + c + d)  << std::endl;
    }
    else{
        std::cout << sum << std::endl; 
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:10: error: 'cin' is not a member of 'std'
    5 |     std::cin >> a >> b >> c >> d;
      |          ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | int main()
a.cc:7:10: error: 'cin' is not a member of 'std'
    7 |     std::cin >> a >> b >> c >> d;
      |          ^~~
a.cc:7:10: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:9:14: error: 'cout' is not a member of 'std'
    9 |         std::cout << (a + b + c + d)  << std::endl;
      |              ^~~~
a.cc:9:14: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:9:47: error: 'endl' is not a member of 'std'
    9 |         std::cout << (a + b + c + d)  << std::endl;
      |                                               ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | int main()
a.cc:12:14: error: 'cout' is not a member of 'std'
   12 |         std::cout << sum << std::endl;
      |              ^~~~
a.cc:12:14: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:12:34: error: 'endl' is not a member of 'std'
   12 |         std::cout << sum << std::endl;
      |                                  ^~~~
a.cc:12:34: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include <iostream>
#include <algorithm>
using namespace std;
int main () {
         int ans;
         int a,b;
         int S=0,T=0;
         for(int i=0;i<4;i++){
                 cin>>a;
                  S+=a;
          }
         for(int j==0;j<4;j++){
                   cin>>b;
                   T+=b;
          }
          ans=max(S,T);
           cout<<ans<<endl;
           return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:19: error: expected ';' before '==' token
   12 |          for(int j==0;j<4;j++){
      |                   ^~
      |                   ;
a.cc:12:19: error: expected primary-expression before '==' token
   12 |          for(int j==0;j<4;j++){
      |                   ^~
a.cc:12:26: error: expected ')' before ';' token
   12 |          for(int j==0;j<4;j++){
      |             ~            ^
      |                          )
a.cc:12:27: error: 'j' was not declared in this scope
   12 |          for(int j==0;j<4;j++){
      |                           ^
Language: C++

//include
//------------------------------------------
#include <bits/stdc++.h> // only for GCC

using namespace std;

//typedef
//------------------------------------------
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<string> vs;
typedef vector<bool> vb;
typedef vector<vb> vvb;
typedef pair<int, int> pii;
typedef long long ll;
typedef unsigned long long ull;

//container util
//------------------------------------------
#define all(a)  (a).begin(),(a).end()
#define rall(a) (a).rbegin(), (a).rend()
#define pb push_back
#define mp make_pair

//repetition
//------------------------------------------
#define loop(i,a,b) for(ull i=(a);i<ull(b);++i)
#define rep(i,n) loop(i,0,n)
#define iter(i,c) for(auto i=(c).begin(); i!=(c).end(); ++i)
#define riter(i,c) for(auto i=(c).rbegin(); i!=(c).rend(); ++i)

//constant
//--------------------------------------------
const double eps = 1e-10;
const double pi  = acos(-1.0);
const double inf = (int)1e8;

// output vector
// ------------------------------------------
namespace std {
    template<typename T>ostream&operator<<(ostream&os, vector<T>const&v){
        iter(it,v) os<<*it<<(it+1==v.end()?"":",");
        return os;
    }
    template<typename T, typename U>ostream&operator<<(ostream&os,const pair<T,U>&p){
        return os << "[" << p.dirst << "," << p.second << "]";
    }
}

//clear memory
// ------------------------------------------
#define clr(a,i) memset((a), (i) ,sizeof(a))

int main(){
   vi a(4),b(4);
   rep(i,4)cin>>a[i];
   rep(i,4)cin>>b[i];
   if(accumulate(all(a),0)>accumulate(all(b),0)) cout << accumulate(all(a),0) endl;
   else cout << accumulate(all(a),0) endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:58:78: error: expected ';' before 'endl'
   58 |    if(accumulate(all(a),0)>accumulate(all(b),0)) cout << accumulate(all(a),0) endl;
      |                                                                              ^~~~~
      |                                                                              ;
a.cc:59:37: error: expected ';' before 'endl'
   59 |    else cout << accumulate(all(a),0) endl;
      |                                     ^~~~~
      |                                     ;
Language: Java

import java.util.*;
public class dareda {
	Scanner sc = new Scanner(System.in);
	int[] a = new int[30];
	int i,n,a1,a2 = 0;

	public void hantei() {
		Arrays.fill(a,0);
		for(i = 0;i <= 29;i++) {
			n = sc.nextInt();
			a[n-1] = 1;
	}
	for(i = 0;i <= 29;i++) {
		if(a[i] != 1) {
			System.out.println(i +1);
		}
	}
	}
	public static void main(String[] args) {
		dareda ou = new dareda();
		ou.hantei();
	}
		// TODO 自動生成されたメソッド・スタブ
}

Compiler output:
Main.java:2: error: class dareda is public, should be declared in a file named dareda.java
public class dareda {
       ^
1 error
Language: Java

import java.util.*;
public class main {
	Scanner sc = new Scanner(System.in);
	int[] a = new int[30];
	int i,n,a1,a2 = 0;

	public void hantei() {
		Arrays.fill(a,0);
		for(i = 0;i <= 29;i++) {
			n = sc.nextInt();
			a[n-1] = 1;
	}
	for(i = 0;i <= 29;i++) {
		if(a[i] != 1) {
			System.out.println(i +1);
		}
	}
	}
	public static void main(String[] args) {
		main ou = new main();
		ou.hantei();
	}
		// TODO 自動生成されたメソッド・スタブ
}

Compiler output:
Main.java:2: error: class main is public, should be declared in a file named main.java
public class main {
       ^
1 error
Language: Java

import java.util.*;
public class dareda {
	Scanner sc = new Scanner(System.in);
	int[] a = new int[30];
	int i,n = 0;

	public void hantei() {
		Arrays.fill(a,0);
		for(i = 0;i <= 29;i++) {
			n = sc.nextInt();
			a[n-1] = 1;
	}
	for(i = 0;i <= 29;i++) {
		if(a[i] != 1) {
			System.out.println(i +1);
		}
	}
	}
	public static void main(String[] args) {
		dareda ou = new dareda();
		ou.hantei();
	}
		// TODO 自動生成されたメソッド・スタブ
}

Compiler output:
Main.java:2: error: class dareda is public, should be declared in a file named dareda.java
public class dareda {
       ^
1 error
Language: Java

import java.util.Scanner;

class Main {
	public static void main(String[] args) {
	Scanner stdIn = new Scanner(System.in);

	int num[31]={},cn=0;
	for(int i=1; i<29; i++){
		int n = stdIn.nextInt();
		num[n]++;
		}
	for(int i=1; i<31; i++){
		if(num[i]==0){
			System.out.println(i);
			cn++;
			}
		for(cn==2)break;	
		}	
	}
}

Compiler output:
Main.java:7: error: ']' expected
	int num[31]={},cn=0;
	        ^
Main.java:7: error: illegal start of expression
	int num[31]={},cn=0;
	              ^
Main.java:17: error: not a statement
		for(cn==2)break;	
		      ^
Main.java:17: error: ';' expected
		for(cn==2)break;	
		         ^
4 errors
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashSet;


class Main

	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		final int NUM = 28;
		final int NUMs = 30;
		ArrayList<Integer> al = new ArrayList<Integer>();
		HashSet<Integer> h = new HashSet<Integer>();
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		for(int i = 0; i < NUM ;i++){
			h.add(Integer.parseInt(in.readLine()));
		}
		for(int i= 0;i < NUMs ;i++){
			if(!h.contains(i+1)){
				System.out.println(i+1);
			}
		}
	}

}

Compiler output:
Main.java:8: error: '{' expected
class Main
          ^
Main.java:10: error: unnamed classes are a preview feature and are disabled by default.
	public static void main(String[] args) throws IOException {
	              ^
  (use --enable-preview to enable unnamed classes)
Main.java:27: error: class, interface, enum, or record expected
}
^
3 errors
Language: Java

import java.util.Scanner;

class Main
{
	public static void main(String args[])
	{
		Scanner sc = new Scanner(System.in);
		boolean submited[] = new boolean[30];
		for (int i = 0; i < 28; i++)
		{
			submited[sc.nextInt() - 1] = true;
		}
		for (int i = 0; i < 30; i++)
		{
			if (!submited)System.out.println(i+1);
		}
	}
}

Compiler output:
Main.java:15: error: bad operand type boolean[] for unary operator '!'
			if (!submited)System.out.println(i+1);
			    ^
1 error
Language: Java

import java.util.Scanner;

class Main{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int[] attendanceNumbers = new int[28];
		for(int i:attendanceNumbers)attendanceNumbers[i] = stdIn.nextInt();
		Arrays.sort(attendanceNumbers);
		
		for(int j=0;j<28;j++){
			if(attendanceNumbers[j]!=(j+1)){
				System.out.println(attendanceNumbers[j]); 
				j++;
			}
		}
	}
}

Compiler output:
Main.java:8: error: cannot find symbol
		Arrays.sort(attendanceNumbers);
		^
  symbol:   variable Arrays
  location: class Main
1 error
Language: Java

import java.util.Scanner;
import java.util.Arrays;

class Main{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int[] attendanceNumbers = new int[28];
		for(int i:attendanceNumbers)attendanceNumbers[i] = stdIn.nextInt();
		Arrays.sort(attendanceNumbers);
		ArrayList<Integer> array = new ArrayList<Integer>();
		for(int j=1;j<=30;j++)array.add(j);
		for(int k:attendanceNumbers)array.remove(k);
		for(int l:attendanceNumbers)System.out.println(l)
	}
}

Compiler output:
Main.java:13: error: ';' expected
		for(int l:attendanceNumbers)System.out.println(l)
		                                                 ^
1 error
Language: Java

import java.util.Scanner;
import java.util.Arrays;

class Main{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		int[] attendanceNumbers = new int[28];
		for(int i:attendanceNumbers)attendanceNumbers[i] = stdIn.nextInt();
		Arrays.sort(attendanceNumbers);
		ArrayList<Integer> array = new ArrayList<Integer>();
		for(int j=1;j<=30;j++)array.add(j);
		for(int k:attendanceNumbers)array.remove(k);
		for(int l:attendanceNumbers)System.out.println(l);
	}
}

Compiler output:
Main.java:10: error: cannot find symbol
		ArrayList<Integer> array = new ArrayList<Integer>();
		^
  symbol:   class ArrayList
  location: class Main
Main.java:10: error: cannot find symbol
		ArrayList<Integer> array = new ArrayList<Integer>();
		                               ^
  symbol:   class ArrayList
  location: class Main
2 errors
Language: Java

import java.util.Scanner;
import java.util.Arrays;
import java.util.ArrayList;

class Main{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		while(true){
			int[] attendanceNumbers = new int[28];
			for(int i=0;i<28;i++)attendanceNumbers[i] = stdIn.nextInt();
			Arrays.sort(attendanceNumbers);
			ArrayList<Integer> array = new ArrayList<Integer>();
			for(i=1;i<=30;i++)array.add(i);
			for(i:attendanceNumbers)array.remove(i);
			for(i:attendanceNumbers)System.out.println(i);
		}
	}
}

Compiler output:
Main.java:14: error: bad initializer for for-loop
			for(i:attendanceNumbers)array.remove(i);
			    ^
Main.java:15: error: bad initializer for for-loop
			for(i:attendanceNumbers)System.out.println(i);
			    ^
2 errors
Language: Java

import java.util.Scanner;
import java.util.Arrays;
import java.util.ArrayList;

class Main{
	public static void main(String[] args){
		Scanner stdIn = new Scanner(System.in);
		while(true){
			int[] attendanceNumbers = new int[28];
			int i;
			for(i=0;i<28;i++)attendanceNumbers[i] = stdIn.nextInt();
			Arrays.sort(attendanceNumbers);
			ArrayList<Integer> array = new ArrayList<Integer>();
			for(i=1;i<=30;i++)array.add(i);
			for(i:attendanceNumbers)array.remove(i);
			for(i:attendanceNumbers)System.out.println(i);
		}
	}
}

Compiler output:
Main.java:15: error: bad initializer for for-loop
			for(i:attendanceNumbers)array.remove(i);
			    ^
Main.java:16: error: bad initializer for for-loop
			for(i:attendanceNumbers)System.out.println(i);
			    ^
2 errors
Language: C

#include <stdio.h>
int main(){
	int data[30];
	int i;
	int in;
	for(i=0;i<30;i++){
		data[i]=0;
	}
	for(i=0;i<28);i++){
		scanf("%d",&in);
		data[in-1]=1;
	}
	for(i=0;i<30;i++){
		if(data[i]==0){
			printf("%d\n",i+1);
		}
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:21: error: expected ';' before ')' token
    9 |         for(i=0;i<28);i++){
      |                     ^
      |                     ;
main.c:9:26: error: expected ';' before ')' token
    9 |         for(i=0;i<28);i++){
      |                          ^
      |                          ;
main.c:9:26: error: expected statement before ')' token
Language: C

#include <cstdio>
#include <set>
using namespace std;
int main()
{
	set<int> se;
	for(int i = 1; i <= 30; i++) se.insert(i);
	for(int i = 0, t; i < 28; i++)
		scanf("%d\n", &t), se.erase(t);
	for(set<int>::iterator it = se.begin(); it != se.end(); it++)
		printf("%d\n", *it);
	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>

using namespace std;


int main(void)
{
	int i, num;
	bool student[30];

	for( i=0; i<30; i++ )
		student[i] = false;

	for( i=0; i<28; i++ ){
		cin >> num;
		student[num-1] = true;
	}

	for( i=0; i<30; i++ )
		if( !student[i] )
			cout << i+1 << 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>

int main(){
	int a[30],b,c=0,d
	for(i=0;i<28;i++){
		scanf("%d",a[i]);
		for(j=0;j<30;j++){
			if(a[i]==j){
				b[i]=1;
				break;
			}else{
				b[i]=0;
			}
		}
	}
	for(i=0;i<28;i++){
		if(b[i]==0&&c==0){
			c=a[i];
		}else if(b[i]==0&&c!=0){
			d=a[i];
		}
	}
	if(c<d){
		printf("%d\n%d\n",c,d);
	}else{
		printf("%d\n%d\n",d,c);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
    5 |         for(i=0;i<28;i++){
      |         ^~~
main.c:5:17: error: 'i' undeclared (first use in this function)
    5 |         for(i=0;i<28;i++){
      |                 ^
main.c:5:17: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:25: error: expected ';' before ')' token
    5 |         for(i=0;i<28;i++){
      |                         ^
      |                         ;
main.c:5:25: error: expected statement before ')' token
main.c:7:21: error: 'j' undeclared (first use in this function)
    7 |                 for(j=0;j<30;j++){
      |                     ^
main.c:20:25: error: 'd' undeclared (first use in this function)
   20 |                         d=a[i];
      |                         ^
Language: C

#include <stdio.h>

int main(){
	int a[30],b,c=0,d,i,j;
	for(i=0;i<28;i++){
		scanf("%d",a[i]);
		for(j=0;j<30;j++){
			if(a[i]==j){
				b[i]=1;
				break;
			}else{
				b[i]=0;
			}
		}
	}
	for(i=0;i<28;i++){
		if(b[i]==0&&c==0){
			c=a[i];
		}else if(b[i]==0&&c!=0){
			d=a[i];
		}
	}
	if(c<d){
		printf("%d\n%d\n",c,d);
	}else{
		printf("%d\n%d\n",d,c);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:34: error: subscripted value is neither array nor pointer nor vector
    9 |                                 b[i]=1;
      |                                  ^
main.c:12:34: error: subscripted value is neither array nor pointer nor vector
   12 |                                 b[i]=0;
      |                                  ^
main.c:17:21: error: subscripted value is neither array nor pointer nor vector
   17 |                 if(b[i]==0&&c==0){
      |                     ^
main.c:19:27: error: subscripted value is neither array nor pointer nor vector
   19 |                 }else if(b[i]==0&&c!=0){
      |                           ^
Language: C

#include <stdio.h>

int main(){
	int a[30],b,i,
	for(i=0;i<28;i++){
		scanf("%d",&a[i]);
	}
	a[28]=10000000;
	for(i=0;i<100000;i++){
		if(a[i]>=a[i+1]){
			b=a[i];
			a[i]=a[i+1];
			a[i+1]=b;
		}
	}
	for(i=0;i<27;i++){
		if(a[i]+3==a[i+1]){
			c=a[i]+1;
			d=a[i]+2;
			printf("%d\n%d\n",c,d);
			return 0;
		}
		if(a[i]+2==a[i+1]){
			if(c==0){
				c=a[i]+1;
			}else{
				d=a[i]+1;
			}
		}
	}
	printf("%d\n%d\n",c,d);
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: expected identifier or '(' before 'for'
    5 |         for(i=0;i<28;i++){
      |         ^~~
main.c:5:25: error: expected ';' before ')' token
    5 |         for(i=0;i<28;i++){
      |                         ^
      |                         ;
main.c:5:25: error: expected statement before ')' token
main.c:18:25: error: 'c' undeclared (first use in this function)
   18 |                         c=a[i]+1;
      |                         ^
main.c:18:25: note: each undeclared identifier is reported only once for each function it appears in
main.c:19:25: error: 'd' undeclared (first use in this function)
   19 |                         d=a[i]+2;
      |                         ^
Language: C

#include<stdio.h>
int a[31];
int main(void){
int i,b;
for(i=0;i<28;i++){
scanf("%d",&b);
a[b]=1;
}
for(i=1;i<31;i++){
if(a[i]==0){
printf("%d\n",i);
}
return 0;
}

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

#include<stdio.h>
int main(){
int number[28],i,j,a=0,b=0,flag;
int (i=0;i<28;i++){
scanf("%d?\n",&number[i]);
}
for(i=0;i<30;i++){
for(j=0;j<28;j++){
if(i==number[j]) flag=1;
}
if(flag==0 && a>0)b=i+1;
if(flag==0 && a==0)a=i+1;
flag=0;
if(b>0)break;
}
printf("%d?\n%d?\n",a,b);
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:7: error: expected ')' before '=' token
    4 | int (i=0;i<28;i++){
      |       ^
      |       )
Language: C

#include<stdio.h>
int main(){
int number[28],i,j,a=0,b=0,flag;
for (i=0;i<28;i++){
scanf("%d?\n",&number[i]);
}
for(i=1;i<=30;i++){
for(j=0;j<28;j++){
if(inumber[j]==i) flag=1;
}
if(flag==0){
if(a==0)a=i;else b=i;
}else{
flag=0;
}
//if(b>0)break;
}
printf("%d?\n%d?\n",a,b);
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:4: error: 'inumber' undeclared (first use in this function); did you mean 'number'?
    9 | if(inumber[j]==i) flag=1;
      |    ^~~~~~~
      |    number
main.c:9:4: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int main(){
int number[28],i,j,a=0,b=0,flag;
for (i=0;i<28;i++){
scanf("%d?\n",&n[i]);
}
for(i=1;i<=30;i++){
for(j=0;j<28;j++){
if(n[j]==i) flag=1;
}
if(flag==0){
if(a==0)a=i;else b=i;
}else{
flag=0;
}
//if(b>0)break;
}
printf("%d?\n%d?\n",a,b);
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:16: error: 'n' undeclared (first use in this function)
    5 | scanf("%d?\n",&n[i]);
      |                ^
main.c:5:16: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>

int main(){

int a[30],i,z;

for(i=1,i<=30,i++){
a[i]=1;
}

for(i=1,i<=28,i++){
scanf("%d",&z);
a[z]=0;
}

for(i=1,i<=30,i++){
if( a[i]==1 ){
 printf("%d\n",i);  }
}

retrun 0;

}

Compiler output:
main.c: In function 'main':
main.c:7:18: error: expected ';' before ')' token
    7 | for(i=1,i<=30,i++){
      |                  ^
      |                  ;
main.c:7:18: error: expected expression before ')' token
main.c:11:18: error: expected ';' before ')' token
   11 | for(i=1,i<=28,i++){
      |                  ^
      |                  ;
main.c:11:18: error: expected expression before ')' token
main.c:16:18: error: expected ';' before ')' token
   16 | for(i=1,i<=30,i++){
      |                  ^
      |                  ;
main.c:16:18: error: expected expression before ')' token
main.c:21:1: error: 'retrun' undeclared (first use in this function)
   21 | retrun 0;
      | ^~~~~~
main.c:21:1: note: each undeclared identifier is reported only once for each function it appears in
main.c:21:7: error: expected ';' before numeric constant
   21 | retrun 0;
      |       ^~
      |       ;
Language: C

#include<stdio.h>

int main(){

int a[30],i,z;

for(i=1;i<=30;i++){
a[i]=1;
}

for(i=1;i<=28;i++){
scanf("%d",&z);
a[z]=0;
}

for(i=1;i<=30;i++){
if( a[i]==1 ){
 printf("%d\n",i);  }
}

retrun 0;

}

Compiler output:
main.c: In function 'main':
main.c:21:1: error: 'retrun' undeclared (first use in this function)
   21 | retrun 0;
      | ^~~~~~
main.c:21:1: note: each undeclared identifier is reported only once for each function it appears in
main.c:21:7: error: expected ';' before numeric constant
   21 | retrun 0;
      |       ^~
      |       ;
Language: C

#include<stdio.h>

int main() {
	int N[31]={0};
	int i;
        int j=0;
	for (i = 0; i < 29; i++) {
		scanf_s("%d", &j);
		N[j] = 1;
	}
	for (i = 0; i < 31; i++) {
		if (N[i] == 0)
			printf_s("%d\n", i);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:17: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    8 |                 scanf_s("%d", &j);
      |                 ^~~~~~~
      |                 scanf
main.c:13:25: error: implicit declaration of function 'printf_s'; did you mean 'printf'? [-Wimplicit-function-declaration]
   13 |                         printf_s("%d\n", i);
      |                         ^~~~~~~~
      |                         printf
Language: C

#include<stdio.h>

int main() {
	int N[31]={0};
	int i;
        int j=0;
	for (i = 0; i < 29; i++) {
		scanf_s("%d", &j);
		N[j] = 1;
	}
	for (i = 1; i < 31; i++) {
		if (N[i] == 0)
			printf("%d\n", i);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:17: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    8 |                 scanf_s("%d", &j);
      |                 ^~~~~~~
      |                 scanf
Language: C

#include <stdio.h>
#include <stdlib.h>

#define N 256

int who[2];

int compar(const void *val1,const void *val2){
	if(*val1<*val2){
		return -1;
	}
	else if(*val1== *val2){
		return 0;
	}
	else{
		return 1;
	}
}

void detect(const int *pnt) {
	int i = 1, j = 0;
	int count = 0;
	while (1) {
		if (i != pnt[j]) {
			who[count] = i;
			count++;
			i++;
			if (count == 2) {
				break;
			}
		}
		else {
			i++;
			j++;
		}
	}
}
int main(void) {
	int stdntID[5];
	int i,j;
	for (i = 0; i<5; i++) {
		scanf("%d", &stdntID[i]);
	}
	qsort(stdntID,5,sizeof(int),compar);
	detect(stdntID);
	printf("%d\n", who[0]);
	printf("%d\n", who[1]);
	return 0;
}


Compiler output:
main.c: In function 'compar':
main.c:9:12: warning: dereferencing 'void *' pointer
    9 |         if(*val1<*val2){
      |            ^~~~~
main.c:9:18: warning: dereferencing 'void *' pointer
    9 |         if(*val1<*val2){
      |                  ^~~~~
main.c:9:12: error: void value not ignored as it ought to be
    9 |         if(*val1<*val2){
      |            ^~~~~
main.c:9:18: error: void value not ignored as it ought to be
    9 |         if(*val1<*val2){
      |                  ^~~~~
main.c:12:17: warning: dereferencing 'void *' pointer
   12 |         else if(*val1== *val2){
      |                 ^~~~~
main.c:12:25: warning: dereferencing 'void *' pointer
   12 |         else if(*val1== *val2){
      |                         ^~~~~
main.c:12:17: error: void value not ignored as it ought to be
   12 |         else if(*val1== *val2){
      |                 ^~~~~
main.c:12:25: error: void value not ignored as it ought to be
   12 |         else if(*val1== *val2){
      |                         ^~~~~
Language: C

#include <stdio.h>int main(){int a=0,n=28,m;while(n--){scanf("%d",&m);a+=(1<<(m-1));}for(n=1;n<31;n++,a>>=1)if(~a&1)printf("%d\n",n);}

Compiler output:
main.c:1:19: warning: extra tokens at end of #include directive
    1 | #include <stdio.h>int main(){int a=0,n=28,m;while(n--){scanf("%d",&m);a+=(1<<(m-1));}for(n=1;n<31;n++,a>>=1)if(~a&1)printf("%d\n",n);}
      |                   ^~~
/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<iostream>
using namespace std;
int main(){
  bool a[31];
  while(1){
    for(int i = 0 ; i < 30 ; i++ ) a[i] = false;
    int d;
    for(int i = 0 ; i < 28 ; i++ ){
      cin>>d;
      a[d] = true;
    }
    for(int i = 1 ; i <= 30 ; i++ ){
      if(a[i]==false)cout<<i<<endl;
    }
  }
}

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

t i = 1 ; i <= 30 ; i++ ){
      if(a[i]==false)cout<<i<<endl;
    }
  }
}

Compiler output:
main.c:1:1: error: unknown type name 't'
    1 | t i = 1 ; i <= 30 ; i++ ){
      | ^
main.c:1:13: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<=' token
    1 | t i = 1 ; i <= 30 ; i++ ){
      |             ^~
main.c:1:22: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
    1 | t i = 1 ; i <= 30 ; i++ ){
      |                      ^~
main.c:4:3: error: expected identifier or '(' before '}' token
    4 |   }
      |   ^
main.c:5:1: error: expected identifier or '(' before '}' token
    5 | }
      | ^
Language: C


#include<iostream>
using namespace std;
int main(){
  bool a[31];
  int d;
  while(cin>>d){
    for(int i = 0 ; i < 30 ; i++ ) a[i] = false;
    for(int i = 0 ; i < 28 ; i++ ){
      a[d] = true;
      if(i!=27)cin>>d;
    }
    for(int i = 1 ; i <= 30 ; i++ ){
      if(a[i]==false)cout<<i<<endl;
    }
  }
}

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

#include<iostream>
using namespace std;
int main(){
  bool a[31];
  int d;
  while(cin>>d){
    for(int i = 0 ; i < 30 ; i++ ) a[i] = false;
    for(int i = 0 ; i < 28 ; i++ ){
      a[d] = true;
      if(i!=27)cin>>d;
    }
    for(int i = 1 ; i <= 30 ; i++ ){
      if(a[i]==false)cout<<i<<endl;
    }
  }
}

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

#include<iostream>
using namespace std;
int main(){
  int a[31];
  int d;
  while(cin>>d){
    for(int i = 0 ; i <= 30 ; i++ ) a[i] = 0;
    for(int i = 0 ; i < 28 ; i++ ){
      a[d] = 1;
      if(i!=27)cin>>d;
    }
    for(int i = 1 ; i <= 30 ; i++ ){
      if(a[i]==0)cout<<i<<endl;
    }
    //for(int i = 1 ; i <= 30 ; i++) cout<<a[d]<<endl;
  }
}

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

////////////////////////////
//情報オリンピック過去問////
//Score				 ////
//AOJ 0511			  ////
////////////////////////////

int <stdio.h>

int main(){
	int a[28];
	int b;	
	int d;
		
	d=465
	
	do{
		scanf("%d",&a[b]);
		b++;
		d=465-a[b]
	}while(b<=28)

	int yet1,yet2;
	
	for(int C=1;C<31;C++){
		for(int d=1;d<29;d++){
			if (C>a[d]||C<a[d]){
				yet1=C;
			}
		]
	}

	yet2=d-yet1;

	int max,min
		
	if(yet1>yet2){max=yet1;min=yet2}
	else{max=yet2;min=yet1}

	printf("%d\n%d\n",max,min);

	return0;

}

//end
	

Compiler output:
main.c:7:5: error: expected identifier or '(' before '<' token
    7 | int <stdio.h>
      |     ^
Language: C


#include<stdio.h>
main(){
  int i,s[50],n[50];
  for(i=1;i<=28;i++){
    s[i]=1;#include<stdio.h>
main(){
  int i,s[50],n[50];
  for(i=1;i<=28;i++){
    s[i]=1;
  }
  for(i=1;i<=28;i++){
    scanf("%d",&n[i]);
    s[n[i]]=0;
  }
  for(i=1;i<=28;i++){
    if(s[i]==1){
      printf("%d\n",i);
    }
  }
  return 0;
}

  }
  for(i=1;i<=28;i++){
    scanf("%d",&n[i]);
    s[n[i]]=0;
  }
  for(i=1;i<=28;i++){
    if(s[i]==1){
      printf("%d\n",i);
    }
  }
  return 0;
}

Compiler output:
main.c:3:1: error: return type defaults to 'int' [-Wimplicit-int]
    3 | main(){
      | ^~~~
main.c: In function 'main':
main.c:6:12: error: stray '#' in program
    6 |     s[i]=1;#include<stdio.h>
      |            ^
main.c:6:13: error: 'include' undeclared (first use in this function)
    6 |     s[i]=1;#include<stdio.h>
      |             ^~~~~~~
main.c:6:13: note: each undeclared identifier is reported only once for each function it appears in
main.c:6:21: error: 'stdio' undeclared (first use in this function); did you mean 'stdin'?
    6 |     s[i]=1;#include<stdio.h>
      |                     ^~~~~
      |                     stdin
main.c:7:7: error: expected ';' before '{' token
    7 | main(){
      |       ^
      |       ;
Language: C

include <stdio.h>

int main(){
  int  flag[31] = {0}, i, input;

  for(i = 1; i < 29;i++){
    scanf("%d", &input);
    flag[input] = 1;
  }

  for(i = 1; i < 31;i++){
    if(flag[i] != 1){
      printf("%d\n", i);
    }
  }

  return 0;
}

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

#include<iostream>
using namespace std;
int main(void)
{
    int student[32],n;
    for(int i=1;i<31;i++){
        student[i]=0;
    }
    for(int i=0;i<28;i++){
        cin>>n;
        student[n]=1;
    }
    for(int i=1;i<31;i++){
        if(student[i]==0)cout<<i<<"\n";
    }
}
　

Compiler output:
a.cc:17:1: error: extended character 　 is not valid in an identifier
   17 | 　
      | ^
a.cc:17:1: error: '\U00003000' does not name a type
   17 | 　
      | ^~