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

#include "stdafx.h"
#include <iostream>
#include <string>
#include <stack>
#include <math.h>
#include <algorithm>
#include <cstdlib>
#include <ctime>
#include <vector>

using namespace std;





int main()
{
	double v;
	double h;
	int n;
	while (cin >> v) {
		n = 1;
		h = 4.9*(v / 9.8)*(v / 9.8);
		while (h > 5 * (n - 1)) {
			n++;
		}
		cout << n << endl;
	}


	return 0;
}

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

#include<stdio.h>
#include<stdlib.h>
#include<iostream>
#include<string>
#include<vector>
#include<math.h>
#include<queue>
#include <algorithm>
#include<functional>
#include<cstdlib>
#include<cmath>


#define REP(i, n) for(int i = 0;i < n;i++)
#define REPR(i, n) for(int i = n;i >= 0;i--)
#define FOR(i, m, n) for(int i = m;i < n;i++)
#define FORR(i, m, n) for(int i = m;i >= n;i--)
#define CI cin >>
#define CO cout <<
#define E << endl;

using namespace std;

typedef pair<int, int> P;
typedef pair<long, long> LP;
typedef pair<int, P> PP;
typedef pair<long, LP> LPP;



int dy[] = { 0, 0, 1, -1, 0 };
int dx[] = { 1, -1, 0, 0, 0 };

int A = 0, B = 0, K = 0, T = 0, W = 0, N = 0, H = 0;
double V = 0;
int n = 0;
double L = 0;
double S = 0;
double ar = 0, br = 0, cr = 0;
int answer = 0;

string C;
string sA, strB;
vector<vector<char>> map;
vector<double> num;
vector<string> str;

int sum = 0;

vector<int> value;
vector<int> weight;

int dp[110][10010];

int data_[210][2] = { -2 };

void input(void) {
	
	return;
}


int main(void) {
	double t = 0;
	double y = 0;
	double N_ = 0;

	while (scanf_s("%lf", &V) != EOF) {
		t = V / 9.8;
		y = 4.9 * t * t;
		N_ = (y + 5) / 5;

		if (N_ == (double)(int)N_) {
			CO (int)N_ E
		}
		else {
			CO (int)N_ + 1 E
		}
	}
	

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:68:16: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
   68 |         while (scanf_s("%lf", &V) != EOF) {
      |                ^~~~~~~
      |                scanf
Language: C++

#include <algorithm>
#include <vector>
#include <math.h>
#include <stdio.h>
#include <cctype>
#include <iostream>
#include <set>
#include <string>
#include <queue>
#include <map>
using namespace std;
int size(string x){
	string::size_type size=x.size();
	return size;
}
#define fu(l,k) for(int i=l;i<k;i++)
#define fd(l,k) for(int i=l;i>k;i--)
#define fi first
#define se second
typedef  vector<string> vs;
typedef  vector<int> vi;
double pi(){
	return M_PI;
}
typedef set<int> set_i;
typedef set<string> set_s;
int main(){
	double n,x,t,h;
	while(cin>>x){
		t=x/9.8;
		h=4.9*t*t;
		n=h/5;
		if(h%5==0) cout<<n-1<<endl;
		else cout<<n<<endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:33:21: error: invalid operands of types 'double' and 'int' to binary 'operator%'
   33 |                 if(h%5==0) cout<<n-1<<endl;
      |                    ~^~
      |                    | |
      |                    | int
      |                    double
Language: C++

#include <algorithm>
#include <vector>
#include <math.h>
#include <stdio.h>
#include <cctype>
#include <iostream>
#include <set>
#include <string>
#include <queue>
#include <map>
using namespace std;
int size(string x){
	string::size_type size=x.size();
	return size;
}
#define fu(l,k) for(int i=l;i<k;i++)
#define fd(l,k) for(int i=l;i>k;i--)
#define fi first
#define se second
typedef  vector<string> vs;
typedef  vector<int> vi;
double pi(){
	return M_PI;
}
typedef set<int> set_i;
typedef set<string> set_s;
int main(){
	double n,x,t,h;
	while(cin>>x){
		t=x/9.8;
		h=4.9*x*x/(9.8*9.8);
		n=h/5;
		if(h%5!=0) cout<<(int)n+2<<endl;
		else cout<<(int)n+1<<endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:33:21: error: invalid operands of types 'double' and 'int' to binary 'operator%'
   33 |                 if(h%5!=0) cout<<(int)n+2<<endl;
      |                    ~^~
      |                    | |
      |                    | int
      |                    double
Language: C++

#include<bits/stdc++.h>
#include<vector>
#include<list>
#include<stack>
#include<queue>
#include<algorithm>
using namespace std;

int main(){
    int mod=1000000007;
    int n;
    int ans;
    double v;
    while (scanf("%lf",&v)!=EOF) {
        for (int i=0;;i++) {
            double t=v/9.8;
            double y=t*t*4.9;
            n=(int)floor((y+5.0)/5.0);
            for (int j=1;;j++) {
                if (j*5-5>=y) {
                    break;
                }
                tmp+=1;
            }
            printf("%d\n",j);
        }
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:23:17: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   23 |                 tmp+=1;
      |                 ^~~
      |                 tm
a.cc:25:27: error: 'j' was not declared in this scope
   25 |             printf("%d\n",j);
      |                           ^
Language: C++

        while com != 'submit' or com != 'next' or com != 'done' :
            com = input()

Compiler output:
a.cc:1:22: warning: multi-character literal with 6 characters exceeds 'int' size of 4 bytes
    1 |         while com != 'submit' or com != 'next' or com != 'done' :
      |                      ^~~~~~~~
a.cc:1:41: warning: multi-character character constant [-Wmultichar]
    1 |         while com != 'submit' or com != 'next' or com != 'done' :
      |                                         ^~~~~~
a.cc:1:58: warning: multi-character character constant [-Wmultichar]
    1 |         while com != 'submit' or com != 'next' or com != 'done' :
      |                                                          ^~~~~~
a.cc:1:9: error: expected unqualified-id before 'while'
    1 |         while com != 'submit' or com != 'next' or com != 'done' :
      |         ^~~~~
Language: C++

#include "bits/stdc++.h"
using namespace std;

int main void{
while(1){
double a;
cin >> a;
double b = a / (9.8);
double c = b*b*(4.9);
double i = 1;
while(1){
if((5*i-5)>=i) break;
i++;
}
cout << i << endl;
}
return 0;
}

Compiler output:
a.cc:4:10: error: expected initializer before 'void'
    4 | int main void{
      |          ^~~~
Language: C++

#include "bits/stdc++.h"
using namespace std;

int main void{
double a;
while(cin >> a){
double b = a / (9.8);
double c = b*b*(4.9);
double i = 1;
while(1){
if((5*i-5)>=i) break;
i++;
}
cout << i << endl;
}
return 0;
}

Compiler output:
a.cc:4:10: error: expected initializer before 'void'
    4 | int main void{
      |          ^~~~
Language: C++

#include<iostream>
int main()
{
	for (double v_min; std::cin >> v_min;)
	{
		double y_min = v_min * v_min / 19.6;
		int y_ceil = static_cast<int>(ceil(y_min));
		int y = y_ceil + (5 - y_ceil % 5) % 5;
		std::cout << (y + 5) / 5 << std::endl;
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:47: error: 'ceil' was not declared in this scope; did you mean 'y_ceil'?
    7 |                 int y_ceil = static_cast<int>(ceil(y_min));
      |                                               ^~~~
      |                                               y_ceil
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  double v;
  while (cin >> v) {
    double t = v / 9.8;
    double y = 4.9 * t * t;
    while (5 * n - 5 < y) {
      n++;
    }
    cout  << n << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:16: error: 'n' was not declared in this scope
    9 |     while (5 * n - 5 < y) {
      |                ^
a.cc:12:14: error: 'n' was not declared in this scope
   12 |     cout  << n << endl;
      |              ^
Language: C++

main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+1.5));}

Compiler output:
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+1.5));}
      | ^~~~
a.cc: In function 'int main()':
a.cc:1:22: error: 'scanf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+1.5));}
      |                      ^~~~~
a.cc:1:37: error: 'printf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+1.5));}
      |                                     ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+1.5));}
Language: C++

main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+2));}

Compiler output:
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+2));}
      | ^~~~
a.cc: In function 'int main()':
a.cc:1:22: error: 'scanf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+2));}
      |                      ^~~~~
a.cc:1:37: error: 'printf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+2));}
      |                                     ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/98+2));}
Language: C++

main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/88+1));}

Compiler output:
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/88+1));}
      | ^~~~
a.cc: In function 'int main()':
a.cc:1:22: error: 'scanf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/88+1));}
      |                      ^~~~~
a.cc:1:37: error: 'printf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/88+1));}
      |                                     ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/88+1));}
Language: C++

main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/87+1));}

Compiler output:
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/87+1));}
      | ^~~~
a.cc: In function 'int main()':
a.cc:1:22: error: 'scanf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/87+1));}
      |                      ^~~~~
a.cc:1:37: error: 'printf' was not declared in this scope
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/87+1));}
      |                                     ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | main(){float v;for(;~scanf("%f",&v);printf("%.f\n",v*v/87+1));}
Language: C++

#include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <cstring>
#include <climits>
#include <cmath>
#include <cfloat>

using namespace std;

double vn, yn, out, tn;

int main()
{
	
	while( cin >> vn, !cin.eof())
	{
		tn = vn/9.8;
		
		yn = 4.9*pow(tn, 2);
		
		for( int i = 1; i < INT_MAX; i++)
		{
			int f = 0, flr = (float)(i-1)*5;
			
			if( flr >= yn )
			{
				cout << i << endl;
				f = 1;
				break;
			}
			
			if(f)
				break;
		}
		
	}
	
	return 0;
}

Compiler output:
a.cc:14:12: error: 'double yn' redeclared as different kind of entity
   14 | double vn, yn, out, tn;
      |            ^~
In file included from /usr/include/features.h:523,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/os_defines.h:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/c++config.h:683,
                 from /usr/include/c++/14/bits/requires_hosted.h:31,
                 from /usr/include/c++/14/iostream:38,
                 from a.cc:1:
/usr/include/x86_64-linux-gnu/bits/mathcalls.h:258:1: note: previous declaration 'double yn(int, double)'
  258 | __MATHCALL (yn,, (int, _Mdouble_));
      | ^~~~~~~~~~
a.cc: In function 'int main()':
a.cc:23:20: error: assignment of function 'double yn(int, double)'
   23 |                 yn = 4.9*pow(tn, 2);
      |                 ~~~^~~~~~~~~~~~~~~~
a.cc:29:33: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   29 |                         if( flr >= yn )
      |                             ~~~~^~~~~
Language: C++

#include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <cstring>
#include <climits>
#include <cmath>
#include <cfloat>

using namespace std;

double vn, yn, out, tn;

int main()
{
	
	while( cin >> vn, !cin.eof())
	{
		tn = vn/9.8;
		
		yn = pow(tn, 2) * 4.9;
		
		for( int i = 1; i < INT_MAX; i++)
		{
			int f = 0;
			double flr = (double)(i-1)*5.0;
			
			if( flr >= yn )
			{
				cout << i << endl;
				f = 1;
				break;
			}
			
			if(f)
				break;
		}
		
	}
	
	return 0;
}

Compiler output:
a.cc:14:12: error: 'double yn' redeclared as different kind of entity
   14 | double vn, yn, out, tn;
      |            ^~
In file included from /usr/include/features.h:523,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/os_defines.h:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/c++config.h:683,
                 from /usr/include/c++/14/bits/requires_hosted.h:31,
                 from /usr/include/c++/14/iostream:38,
                 from a.cc:1:
/usr/include/x86_64-linux-gnu/bits/mathcalls.h:258:1: note: previous declaration 'double yn(int, double)'
  258 | __MATHCALL (yn,, (int, _Mdouble_));
      | ^~~~~~~~~~
a.cc: In function 'int main()':
a.cc:23:20: error: assignment of function 'double yn(int, double)'
   23 |                 yn = pow(tn, 2) * 4.9;
      |                 ~~~^~~~~~~~~~~~~~~~~~
a.cc:30:33: error: invalid operands of types 'double' and 'double(int, double) noexcept' to binary 'operator>='
   30 |                         if( flr >= yn )
      |                             ~~~ ^~ ~~
      |                             |      |
      |                             double double(int, double) noexcept
Language: C++

#include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <cstring>
#include <climits>
#include <cmath>
#include <cfloat>

using namespace std;

double vn, yn, out, tn;

int main()
{
	
	while( cin >> vn, !cin.eof())
	{
		tn = vn/9.8;
		
		yn = tn*tn*4.9;
		
		for( int i = 1; i < INT_MAX; i++)
		{
			int f = 0;
			double flr = (double)(i-1)*5.0;
			
			if( flr >= yn )
			{
				cout << i << endl;
				f = 1;
				break;
			}
			
			if(f)
				break;
		}
		
	}
	
	return 0;
}

Compiler output:
a.cc:14:12: error: 'double yn' redeclared as different kind of entity
   14 | double vn, yn, out, tn;
      |            ^~
In file included from /usr/include/features.h:523,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/os_defines.h:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/c++config.h:683,
                 from /usr/include/c++/14/bits/requires_hosted.h:31,
                 from /usr/include/c++/14/iostream:38,
                 from a.cc:1:
/usr/include/x86_64-linux-gnu/bits/mathcalls.h:258:1: note: previous declaration 'double yn(int, double)'
  258 | __MATHCALL (yn,, (int, _Mdouble_));
      | ^~~~~~~~~~
a.cc: In function 'int main()':
a.cc:23:20: error: assignment of function 'double yn(int, double)'
   23 |                 yn = tn*tn*4.9;
      |                 ~~~^~~~~~~~~~~
a.cc:30:33: error: invalid operands of types 'double' and 'double(int, double) noexcept' to binary 'operator>='
   30 |                         if( flr >= yn )
      |                             ~~~ ^~ ~~
      |                             |      |
      |                             double double(int, double) noexcept
Language: C++

#include<iostream>
using namespace std;

int main(void){
  const double g = 9.8;
  const double height = 5.0;
  double v, y;
  int N;
  while(cin >> v){
    y = (v * v) / (2 * g);
    N = y / height + 1;
    if(y % height != 0)
      N++;
    
    cout << N << endl;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:10: error: invalid operands of types 'double' and 'const double' to binary 'operator%'
   12 |     if(y % height != 0)
      |        ~ ^ ~~~~~~
      |        |   |
      |        |   const double
      |        double
Language: C++

#include <stdio.h>
int main() {double h;while (scanf("%lf",&h)!=EOF) printf("%d\n",(int)(ceil((((h*h*4.9/9.8)/9.8+5.0)/5.0)+1e-9))); return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:2:71: error: 'ceil' was not declared in this scope
    2 | int main() {double h;while (scanf("%lf",&h)!=EOF) printf("%d\n",(int)(ceil((((h*h*4.9/9.8)/9.8+5.0)/5.0)+1e-9))); return 0;}
      |                                                                       ^~~~
Language: C++

bool solve(){
	double in;
	while(cin>>in){
		int y = 4.9 * (in/9.8) * (in/9.8);
		int ans = 0;
		for(int i=1;i<10000;i++){
			int h = 5 * (i - 1);
			if(h > y){
				ans = i;
				break;
			}
		}
		cout<< ans<< endl;
	}
	return true;
}

Compiler output:
a.cc: In function 'bool solve()':
a.cc:3:15: error: 'cin' was not declared in this scope; did you mean 'in'?
    3 |         while(cin>>in){
      |               ^~~
      |               in
a.cc:13:17: error: 'cout' was not declared in this scope
   13 |                 cout<< ans<< endl;
      |                 ^~~~
a.cc:13:30: error: 'endl' was not declared in this scope
   13 |                 cout<< ans<< endl;
      |                              ^~~~
Language: C++

#include<iostream>
using namespace std;

int main(){
	double mv;
	while (cin >> mv)
		cout << ceil((mv*mv / (9.8f * 2)) / 5 + 1) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:25: error: 'ceil' was not declared in this scope
    7 |                 cout << ceil((mv*mv / (9.8f * 2)) / 5 + 1) << endl;
      |                         ^~~~
Language: C++

//include----------------------------------------------------------------------------------------------------------------------
#include <bits/stdc++.h>

//using namespace--------------------------------------------------------------------------------------------------------------
using namespace std;

//define-----------------------------------------------------------------------------------------------------------------------
#define rep(i, n) for(int i = 0; i < n; i++)
#define FOR(i, s, n) for(int i = s; i < n; i++)
#define per(i, n) for(int i = n; i >= 0; i--)
#define ROF(i, s, n) for(int i = s; i >= n; i--)
#define FORIT(i, A) for (auto i : A)
#define PRINT(x) cout << (x) << endl
#define ALL(a)  (a).begin(),(a).end()
#define RALL(a) (a).rbegin(), (a).rend()
#define PB push_back
#define MP make_pair
#define FOREACH(i, n) for (__typeof((n).begin()) i = (n).begin(); i != (n).end(); ++i)
#define SZ(a) int((a).size())
#define EACH(i,c) for(typeof((c).begin()) i=(c).begin(); i!=(c).end(); ++i)
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define SORT(c) sort((c).begin(),(c).end())
#define INF 1 << 25
#define CLR(a) memset((a), 0 ,sizeof(a))
#define dump(x)  cerr << #x << " = " << (x) << endl;
#define debug(x) cerr << #x << " = " << (x) << " (L" << __LINE__ << ")" << " " << __FILE__ << endl;
#define sq(n) (n) * (n)

//typedef----------------------------------------------------------------------------------------------------------------------
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<string> VS;
typedef pair<int, int> PII;
typedef long long LL;
typedef unsigned int uint;
typedef unsigned long long ull;

//const------------------------------------------------------------------------------------------------------------------------
const double EPS = 1e-10;
const double PI = acos( -1.0 );

//global-----------------------------------------------------------------------------------------------------------------------
double a;
double test;

//function---------------------------------------------------------------------------------------------------------------------
void main() {
	while ( scanf( "%lf", &a ) != EOF ) {
		for ( int i = 1;; i++ ) {
			test = ( i * 5 - 5 ) / 4.9;
			test = sqrt( test );
			if ( test * 9.8 >= a ) {
				printf( "%d\n", i );
				break;
			}
		}
	}
}

Compiler output:
a.cc:47:1: error: '::main' must return 'int'
   47 | void main() {
      | ^~~~
Language: C++

//include----------------------------------------------------------------------------------------------------------------------
#include <bits/stdc++.h>

//using namespace--------------------------------------------------------------------------------------------------------------
using namespace std;

//define-----------------------------------------------------------------------------------------------------------------------
#define rep(i, n) for(int i = 0; i < n; i++)
#define FOR(i, s, n) for(int i = s; i < n; i++)
#define per(i, n) for(int i = n; i >= 0; i--)
#define ROF(i, s, n) for(int i = s; i >= n; i--)
#define FORIT(i, A) for (auto i : A)
#define PRINT(x) cout << (x) << endl
#define ALL(a)  (a).begin(),(a).end()
#define RALL(a) (a).rbegin(), (a).rend()
#define PB push_back
#define MP make_pair
#define FOREACH(i, n) for (__typeof((n).begin()) i = (n).begin(); i != (n).end(); ++i)
#define SZ(a) int((a).size())
#define EACH(i,c) for(typeof((c).begin()) i=(c).begin(); i!=(c).end(); ++i)
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define SORT(c) sort((c).begin(),(c).end())
#define INF 1 << 25
#define CLR(a) memset((a), 0 ,sizeof(a))
#define dump(x)  cerr << #x << " = " << (x) << endl;
#define debug(x) cerr << #x << " = " << (x) << " (L" << __LINE__ << ")" << " " << __FILE__ << endl;
#define sq(n) (n) * (n)

//typedef----------------------------------------------------------------------------------------------------------------------
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<string> VS;
typedef pair<int, int> PII;
typedef long long LL;
typedef unsigned int uint;
typedef unsigned long long ull;

//const------------------------------------------------------------------------------------------------------------------------
const double EPS = 1e-10;
const double PI = acos( -1.0 );

//global-----------------------------------------------------------------------------------------------------------------------
double a;
double test;

//function---------------------------------------------------------------------------------------------------------------------
void main() {
	while ( scanf( "%lf", &a ) != EOF ) {
		for ( int i = 2;; i++ ) {
			test = ( i * 5 - 5 );
			test /= 4.9;
			test = sqrt( test );
			if ( test * 9.8 >= a ) {
				printf( "%d\n", i );
				break;
			}
		}
	}
}

Compiler output:
a.cc:47:1: error: '::main' must return 'int'
   47 | void main() {
      | ^~~~
Language: C++

#include <iostream>
using namespace std;


int main()
{
	double s;
	while (cin >> s){
		for (int i = 1;; i++){
			double h = 5 * i - 5;
			double v = sqrt(2 * 9.8 * h);
			if (v >= s){
				cout << i << endl;
				break;
			}
		}
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:36: error: 'sqrt' was not declared in this scope
   11 |                         double v = sqrt(2 * 9.8 * h);
      |                                    ^~~~
Language: C++

// -*- coding: utf-8 -*-
// Last-Updated : <2014/06/19 00:36:03 by samui>

#include <algorithm>
#include <iostream>
#include <cstdio>
#include <string>
#include <vector>
#include <climits>
#define MP(a, b) make_pair(a, b)
#define X first
#define Y second
#define rep(i,n) for(int (i) = 0; (i) < (int)(n); ++(i))
#define rer(i,l,n) for(int (i) = l; (i) <= (int)(n); ++(i))
#define reu(i,l,n) for(int (i) = l; (i) < (int)(n); ++(i))
template<typename T,typename U> inline void amin(T &x,U y){ if(y<x) x = y;}
template<typename T,typename U> inline void amax(T &x,U y){ if(x<y) x = y;}
template<typename TYPE,std::size_t SIZE>
std::size_t len(const TYPE (&array)[SIZE]){return SIZE;}

int main(int argc, char *argv[])
{
  float a;
  while(std::cin>>a){
    abc(a);
  }
  return 0;
}
int abc(float x)
{

  float t = x/9.8;
  float y = t*t*4.9;;
  float ans = int((y+5)/5);
  float a = (y+5)/5-ans;
  if(a>0)
    ans++;
  std::cout<<ans<<std::endl;


  return 0;
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:25:5: error: 'abc' was not declared in this scope; did you mean 'abs'?
   25 |     abc(a);
      |     ^~~
      |     abs
Language: Java

import java.util.Scanner;
import java.util.TreeSet;
public class test{
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String st;
		TreeSet<String> set;
		while((st = sc.nextLine()) != null){
			int hit = 0, blow = 0;
			set = new TreeSet<String>();
			String[] a = st.split(" ");
			String[] b = sc.nextLine().split(" ");
			for(int i = 0; i < 4; i++)
				set.add(a[i]);
			for(int i = 0; i < 4; i++)
				if(a[i].equals(b[i])){
					hit++;
					set.remove(a[i]);
				}
			for(int i = 0; i < 4; i++)
				if(set.contains(b[i]))
					blow++;
			System.out.println(hit+" "+blow);
		}
	}
}

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

import java.util.ArrayList;


public class A 
{

	public static void main (String[] args)
	{
		int hit =0;
		int blow =0;
		
		int n = args.length/8;
		
		int index =0;
		for(int i = 0; i < n; i++) 
		{
			ArrayList<String> a = new ArrayList<String>();
			for (int p=0;p<4;p++)
			{a.add(args[index]);index++;}
			
			ArrayList<String> b = new ArrayList<String>();
			for (int q=0;q<4;q++)
			{b.add(args[index]);index++;}
			
			int k=0;
			while (k<a.size())
			{
				if (a.get(k).equals(b.get(k)))
				{
					hit++;
					a.remove(k);b.remove(k);
					k--;
				}
				k++;
			}
			
			if (a.size()!=0)
			{
				for (int x=0;x<a.size();x++)
				{
					for (int y=0;y<b.size();y++)
					{
						if (x==y)
							continue;
						if(a.get(x).equals(b.get(y)))
							blow++;
					}
				}
			}
			System.out.println(hit+" "+blow);
		
        }
		
		
	}
}

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

public static void main (String[] args)
	{
		int hit =0;
		int blow =0;
		
		int n = args.length/8;
		
		int index =0;
		for(int i = 0; i < n; i++) 
		{
			ArrayList<String> a = new ArrayList<String>();
			for (int p=0;p<4;p++)
			{a.add(args[index]);index++;}
			
			ArrayList<String> b = new ArrayList<String>();
			for (int q=0;q<4;q++)
			{b.add(args[index]);index++;}
			
			int k=0;
			while (k<a.size())
			{
				if (a.get(k).equals(b.get(k)))
				{
					hit++;
					a.remove(k);b.remove(k);
					k--;
				}
				k++;
			}
			
			if (a.size()!=0)
			{
				for (int x=0;x<a.size();x++)
				{
					for (int y=0;y<b.size();y++)
					{
						if (x==y)
							continue;
						if(a.get(x).equals(b.get(y)))
							blow++;
					}
				}
			}
			System.out.println(hit+" "+blow);
		
        }
		
		
	}

Compiler output:
Main.java:1: error: unnamed classes are a preview feature and are disabled by default.
public static void main (String[] args)
              ^
  (use --enable-preview to enable unnamed classes)
1 error
Language: Java

import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;

public class LeetCode {
	
	public static void main(String[] args) {
		
		// Set up
		Scanner in = new Scanner(System.in);
		
		// Multiple games
        while (in.hasNextInt()) {
			
			// Read in data to A and B
    		int[] A = new int[4];
    		int[] B = new int[4];
			for (int i = 0; i < 4; i++) {
				A[i] = in.nextInt();
			}
			for (int i = 0; i < 4; i++) {
				B[i] = in.nextInt();
			}
			
			// Populate D
			int[] D = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
			for (int i = 0; i < 4; i++) {
				if (A[i] != B[i]) {
					D[A[i]]++;
				}
			}
			
			// Count results
			int num_hits = 0;
    		int num_blows = 0;
			for (int i = 0; i < 4; i++) {
				if (A[i] == B[i]) {
					num_hits++;
				}
				else if (D[B[i]] == 1) {
					num_blows++;
				}
			}
			
			// Print results
			System.out.println(num_hits + " " + num_blows);
			
        }
        
        // Done
        in.close();
		
	}
	
}

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

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		while(s.hasNext()){
			int[] a = new int[8];
			int hit = 0;
			int blow = 0;
			for(int i=0 ; i<4 ; i++)
				a[i] = s.nextInt();
			for(int i=0 ; i<4 ; i++){
				b[i] = s.nextInt();
				if(a[i] == b[i])
					hit += 1;
			}
			for(int i=0 ; i<4 ; i++){
				for(int j=0 ; j<4 ; j++){
					if(a[i]==a[j])
						blow += 1;
				}
			}
			System.out.println(hit+" "+blow);
		}
    }
}

Compiler output:
Main.java:14: error: cannot find symbol
				b[i] = s.nextInt();
				^
  symbol:   variable b
  location: class Main
Main.java:15: error: cannot find symbol
				if(a[i] == b[i])
				           ^
  symbol:   variable b
  location: class Main
2 errors
Language: C

#include <stdio.h>
#include <conio.h>

int main(){
	int a[4];
	int b[4];
	int hit,blow;
	int i,j;
	
	while(1){
		hit=0;
		blow=0;
		if(_kbhit()==0){
			break;
		}
		scanf("%d %d %d %d",&a[0],&a[1],&a[2],&a[3]);
		scanf("%d %d %d %d",&b[0],&b[1],&b[2],&b[3]);
		
		for(i=0;i<4;i++){
			for(j=0;j<4;j++){
				if(a[i]==b[j]){
					blow++;
				}
			}
			if(a[i]==b[i]){
				hit++;
			}
		}
		blow-=hit;
		printf("%d %d\n",hit,blow);
	}
	return 0;
}

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

#include<stdio.h>   
 #include<conio.h>
int main(void){
int  a[4],b[4] ,i,j;
while(scanf("%d %d %d %d",&a[0],&a[1],&a[2],&a[3])!=EOF)
	{    scanf("%d %d %d %d",&b[0],&b[1],&b[2],&b[3]);
	
int	hit=0,blow=0;
	for(i=0;i<4;i++){
    if(a[i]==b[i]){
	
			hit++;
	}
		
		}
		for(i=0;i<4;i++){
			for(j=0;j<4;j++){
				if(a[i]==b[j]){
					blow++;
				}
			}
		}
		printf("%d %d\n", hit, blow);
	}



	return 0;
}

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

#include<stdio.h>

int main(void){

	int a[5],b[5],i,j,hit=0,blow=0;
	
	while()
	
	for(i=0;i<4;i++)scanf("%d",&a[i]);
	for(i=0;i<4;i++)scanf("%d",&b[i]);
	
	for(i=0;i<4;i++){
		if(a[i]==b[i])hit++;
		
		for(j=0;j<4;j++){
			if(a[i]==b[j] &&a[i]!=b[i])blow++;
		}
	}
	
	printf("%d%d\n",hit,blow);
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:15: error: expected expression before ')' token
    7 |         while()
      |               ^
Language: C

#include <stdio.h>

int main(void) {
	int i, j;
	int hit = 0, blow = 0;
	int a[4], b[4];
	int count = 0;
	
	while (scanf("%d %d %d %d", &a[0], &a[1], &a[2], &a[3]) != EOF){
		scanf("%d %d %d %d", &b[0], &b[1], &b[2], &b[3]);
		count++;
		
		for (i = 0; i < 4; i++){
if (a[i] == b[i]){
hit++;
}
			for (j = 0; j < 4; j++){
				else if (i != j && a[i] == b[j]){
					blow++;
				}
			}
		}
		printf("%d %d\n", hit, blow);
hit = 0;blow = 0;
	}
	// your code goes here
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:18:33: error: 'else' without a previous 'if'
   18 |                                 else if (i != j && a[i] == b[j]){
      |                                 ^~~~
Language: C

#include<stdio.h>

int main(void){
	
	int d1[4],d2[4];
	short flag[4];
	
	int i,j,k,l;
	int h,b;
	
	h = 0;
	b = 0;
	
	scanf(" %d %d %d %d",d1[0],d1[1],d1[2],d1[3]);
	scanf(" %d %d %d %d",d2[0],d2[1],d2[2],d2[3]);
	
	for(i = 0;i < 4;i++){
		if(d1[i] == d2[i]){
			flag[i] == 1;
		}
	}
	
	for(i = 0;i < 4;i++){
		if(flag[i]==1){
			continue;
		}
		for(j = 0;j < 4;j++){
			if(flag[j]==1){
				continue;
			}else if(d1[i] == d2[f]){
				b++;
			}
		}
	}
	
	for(i = 0;i < 4;i++){
		if(flag[i]==1){
			h++;
		}
	}
	
	printf("%d %d",h,b);
	
	return(0);
	
}

Compiler output:
main.c: In function 'main':
main.c:30:46: error: 'f' undeclared (first use in this function)
   30 |                         }else if(d1[i] == d2[f]){
      |                                              ^
main.c:30:46: note: each undeclared identifier is reported only once for each function it appears in
Language: C


#include<iostream>
#include<stdio.h>
#include<algorithm>

using namespace std;

int main(){
	pair<int,int>  p1,p2,p3,p4;
	int a[4];
	int b[4];

	while(scanf("%d %d %d %d",&a[0],&a[1],&a[2],&a[3]) != EOF){
		int hit = 0;
		int blow = 0;
		//scanf("%d %d %d %d",&b[0],&b[1],&b[2],&b[3]);

		for(int i=0;i<4;i++){
			scanf("%d",&b[i]);
				if(a[i] == b[i]){
					hit++;
				}
				for(int j=0;j<4;j++){
						if(b[i] == a[j] and a[i] != b[i]){
							blow++;
						}
				}
		}
	cout << hit << " " << blow << endl;
	}
	return 0;
}

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

#include <iostream>
#include <cstdio>

using namespace std;

int main(){
	int a[4], b[4];
	while (scanf("%d %d %d %d %d %d %d %d", &a[0], &a[1], &a[2], &a[3], &b[0], &b[1], &b[2], &b[3])){
		int hit = 0;
		int blow = 0;
		for (int i = 0; i < 4; i++){
			for (int j = 0; j < 4; j++){
				if (a[i] == b[j]){
					if (i == j) hit++;
					else blow++;
				}
			}
		}
		printf("%d %d\n", hit, blow);
	}
	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 a[100], b[100], i, n, h, b;
   while(scanf("%d %d %d %d %d %d %d %d", &a[0], &a[1], &a[2], &a[3], &b[0] &b[1], &b[1], &b[2], &b[3]) != 0){
      h = 0;
      b = 0;
      for(i = 0; i < 4; i++){
         if(a[i] == b[i]){
            h++;
         }
      }
      for(i = 0; i < 4; i++){
         for(l = 0; l < 4; l++){
            if(a[i] = b[l]){
               b++;
            }
         }
      }
      printf("%d %d\n", h, b);
   }
   return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:33: error: conflicting types for 'b'; have 'int'
    3 |    int a[100], b[100], i, n, h, b;
      |                                 ^
main.c:3:16: note: previous declaration of 'b' with type 'int[100]'
    3 |    int a[100], b[100], i, n, h, b;
      |                ^
main.c:13:14: error: 'l' undeclared (first use in this function)
   13 |          for(l = 0; l < 4; l++){
      |              ^
main.c:13:14: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#nclude <stdio.h>
main(){
  int a[4],b[4],h=0,v=0,i;
  while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
    for(i=0;i<4;i++){
      if(a[i]==b[i]) h++;
    }
    for(i=0;i<4;i++){
      if(a[i]==b[0]||a[i]==b[1]||a[i]==b[2]||a[i]==b[3]) v++;
    }
    printf("%d %d\n",h,v);
  }

  return 0; 
}

Compiler output:
main.c:1:2: error: invalid preprocessing directive #nclude; did you mean #include?
    1 | #nclude <stdio.h>
      |  ^~~~~~
      |  include
main.c:2:1: error: return type defaults to 'int' [-Wimplicit-int]
    2 | main(){
      | ^~~~
main.c: In function 'main':
main.c:4:9: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    4 |   while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
      |         ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | #nclude <stdio.h>
main.c:4:9: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    4 |   while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
      |         ^~~~~
main.c:4:9: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:4:85: error: 'EOF' undeclared (first use in this function)
    4 |   while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
      |                                                                                     ^~~
main.c:4:85: note: 'EOF' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
main.c:4:85: note: each undeclared identifier is reported only once for each function it appears in
main.c:11:5: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   11 |     printf("%d %d\n",h,v);
      |     ^~~~~~
main.c:11:5: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:11:5: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:11:5: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

#include <stdio.h>
main(){
  while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
  int a[4],b[4],h=0,v=0,i,c[4];
  c[0]=11;
  c[1]=11;
  c[2]=11;
  c[3]=11;
    for(i=0;i<4;i++){
      if(a[i]==b[i]){
	h++;
	c[i]=a[i];
      }
    }
    for(i=0;i<4;i++){
      if((a[i]==b[0]||a[i]==b[1]||a[i]==b[2]||a[i]==b[3])&&a[i]!=c[i]) v++;
    }
    printf("%d %d\n",h,v);
  }

  return 0; 
}

Compiler output:
main.c:2:1: error: return type defaults to 'int' [-Wimplicit-int]
    2 | main(){
      | ^~~~
main.c: In function 'main':
main.c:3:35: error: 'a' undeclared (first use in this function)
    3 |   while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
      |                                   ^
main.c:3:35: note: each undeclared identifier is reported only once for each function it appears in
main.c:3:59: error: 'b' undeclared (first use in this function)
    3 |   while(scanf("%d%d%d%d%d%d%d%d",&a[0],&a[1],&a[2],&a[3],&b[0],&b[1],&b[2],&b[3]) !=EOF){
      |                                                           ^
Language: C

#include<stdio.h>

int main(){
 int im[4],bl[4],i,hit,blow,j;
 
 while(scanf("%d %d %d %d",im,im+1,im+2,im+3)!=EOF){
  scanf("%d %d %d %d",bl,bl+1,bl+2,bl+3);
  for(hit=0,blow=0,i=0;i<4;i++){
   if(im[i]==bl[i]) hit++;
   for(j=0;j<4;j++)
    if(i!=j&&im[i]==bl[j]) blow++;
   printf("%d %d\n",hit,blow);
 }

 return 0;
}

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

#include<stdio.h>   int main() {     int i,j,a[4],b[4],hit=0,blow=0;     while(scanf("%d %d %d %d",&a[0],&a[1],&a[2],&a[3])!=EOF | scanf("%d %d %d %d",&b[0],&b[1],&b[2],&b[3])!=EOF)     {         for(i=0;i<4;i++)         {             if(a[i]==b[i])                 hit++;         }                   for(i=0;i<4;i++)         {             for(j=0;j<4;j++)             {                 if(a[i]==b[j])                     blow++;             }         }         blow = blow -hit;         printf("%d %d\n",hit,blow);         blow = hit = 0;     } } 

Compiler output:
main.c:1:21: warning: extra tokens at end of #include directive
    1 | #include<stdio.h>   int main() {     int i,j,a[4],b[4],hit=0,blow=0;     while(scanf("%d %d %d %d",&a[0],&a[1],&a[2],&a[3])!=EOF | scanf("%d %d %d %d",&b[0],&b[1],&b[2],&b[3])!=EOF)     {         for(i=0;i<4;i++)         {             if(a[i]==b[i])                 hit++;         }                   for(i=0;i<4;i++)         {             for(j=0;j<4;j++)             {                 if(a[i]==b[j])                     blow++;             }         }         blow = blow -hit;         printf("%d %d\n",hit,blow);         blow = hit = 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 <cstdio>
#include <cstring>
#include <algorithm>
#include <iostream>
#include <cmath>
using namespace std;

int main()
{
	//freopen("1.in","r",stdin);
	int a[4],b[4],H,B;
    while(~scanf("%d",a))
    {
        H=B=0;
        scanf("%d %d %d",a+1,a+2,a+3);
        scanf("%d %d %d %d",b,b+1,b+2,b+3);
        for(int i=0;i<4;i++)
        {
            for(int j=0;j<4;j++)
            {
                if(b[i]==a[j])
                {
                    if(i==j) {H++;break;}
                    else {B++;break;}
                }
            }
        }
        printf("%d %d\n",H,B);
    }


	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 a[4], b[4], g, h, i, n, m, hit, blow;

  hit = 0;
  blow = 0;

  for(g = 0; g < 4; g += 1) {
    scanf("%d", &a[g]);
  };
  for(h = 0; h < 4; h += 1) {
    scanf("%d", &b[gh);
  };
  for(n = 0; n < 4; n += 1) {
    for(m = 0; m < 4; m += 1) {
      if(n == m && a[n] == b[m]){
        hit += 1;
      } else if( n != m && a[n] == b[m]) {
        blow += 1;
      };
    };
  };
  printf("%d %d\n", hit, blow);

  return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:13:20: error: 'gh' undeclared (first use in this function); did you mean 'h'?
   13 |     scanf("%d", &b[gh);
      |                    ^~
      |                    h
main.c:13:20: note: each undeclared identifier is reported only once for each function it appears in
main.c:13:22: error: expected ']' before ')' token
   13 |     scanf("%d", &b[gh);
      |                      ^
      |                      ]
Language: C

#include<stdio.h>
 
int main() {
  int a[4], b[4], g, h, i, n, m, hit, blow;
 
  hit = 0;
  blow = 0;
 
  while(scanf("%d", &a[0]) != EOF) {
    for(g = 1; g < 4; g += 1) {
      scanf("%d", &a[g]);
    };
    for(h = 0; h < 4; h += 1) {
      scanf("%d", &b[h]);
    };
    for(n = 0; n < 4; n += 1) {
      for(m = 0; m < 4; m += 1) {
        if(a[n] == b[m)]{
          if(n == m) {
            hit += 1;
          } else {
            blow += 1;
          };
        };
      };
    };
    printf("%d %d\n", hit, blow);
  };
  return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:18:23: error: expected ']' before ')' token
   18 |         if(a[n] == b[m)]{
      |                       ^
      |                       ]
main.c:18:24: error: expected statement before ']' token
   18 |         if(a[n] == b[m)]{
      |                        ^
Language: C

#include<stdio.h>
  
int main() {
  int a[4], b[4], g, h, i, n, m, hit, blow;
  
  hit = 0;
  blow = 0;
  
  while(scanf("%d", &a[0]) != EOF) {
    for(g = 1; g < 4; g += 1) {
      scanf("%d", &a[g]);
    };
    for(h = 0; h < 4; h += 1) {
      scanf("%d", &b[h]);
    };
    for(n = 0; n < 4; n += 1) {
      for(m = 0; m < 4; m += 1) {
        if(a[n] == b[m]{
          if(n == m) {
            hit += 1;
          } else {
            blow += 1;
          };
        };
      };
    };
    printf("%d %d\n", hit, blow);
  };
  return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:18:24: error: expected ')' before '{' token
   18 |         if(a[n] == b[m]{
      |           ~            ^
      |                        )
main.c:25:7: error: expected expression before '}' token
   25 |       };
      |       ^
Language: C

#include <stdio.h>

void input_int(int a[], int b[]);

int main(void)
{
	int a[4], b[4];
	int hit, blow;
	int i, j;
	
	while (1){
		if (a[0] == EOF){
			break;
		}
		hit = blow = 0;
	
		input_int(a, b);
	
 			for (j = ; j < 4; j++){
				if (b[i] == a[j] && i == j){
					hit++;
				}
				else if (b[i] == a[j]){
					blow++;
				}
			}
		}
	
		printf("%d %d\n", hit, blow);
	}
	return (0);
}
void input_int(int a[], int b[])
{
	int i;
	
	for (i = 1; i <= 4; i++){
		scanf("%d", &a[i]);
	}
	for (i = 0; i < 4; i++){
		scanf("%d", &b[i]);
	}
}

Compiler output:
main.c: In function 'main':
main.c:19:34: error: expected expression before ';' token
   19 |                         for (j = ; j < 4; j++){
      |                                  ^
main.c: At top level:
main.c:31:9: error: expected identifier or '(' before 'return'
   31 |         return (0);
      |         ^~~~~~
main.c:32:1: error: expected identifier or '(' before '}' token
   32 | }
      | ^
Language: C

#include <stdio.h>

int main(void){
  int a[4],b[4];
  int i;
  int h,b;
   while( scanf("%d",&a[0]) != EOF){
    h=0; b=0;
   for(i=1; i<4; i++){
     scanf("%d",&a[i]);
}
   for(i=0; i<4; i++){
     scanf("%d",&b[i]);
}
    for(i=0;i<4;i++){
       if(a[i] == b[i])
           h++;
       if(a[i] == b[(i+1)%4]||a[i] == b[(i+2)%4]||a[i] == b[(i+3)%4]) 
           b++;
     }
     printf("%d %d\n",h,b);
}
     return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:9: error: conflicting types for 'b'; have 'int'
    6 |   int h,b;
      |         ^
main.c:4:12: note: previous declaration of 'b' with type 'int[4]'
    4 |   int a[4],b[4];
      |            ^
Language: C

#include <stdio.h>

int main(void){
  int a[4];
  int b[4];
  int i;
  int h,b;
   while( scanf("%d",&a[0]) != EOF){
    h=0; b=0;
   for(i=1; i<4; i++){
     scanf("%d",&a[i]);
}
   for(i=0; i<4; i++){
     scanf("%d",&b[i]);
}
    for(i=0;i<4;i++){
       if(a[i] == b[i])
           h++;
       if(a[i] == b[(i+1)%4]||a[i] == b[(i+2)%4]||a[i] == b[(i+3)%4]) 
           b++;
     }
     printf("%d %d\n",h,b);
}
     return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:9: error: conflicting types for 'b'; have 'int'
    7 |   int h,b;
      |         ^
main.c:5:7: note: previous declaration of 'b' with type 'int[4]'
    5 |   int b[4];
      |       ^
Language: C

#include <stdio.h>

int main(void){
  int a[4];
  int b[4];
  int i,j,k,l;
  int h,b;
   while( scanf("%d",&a[0]) != EOF){
    h=0; b=0;
   for(i=1; i<4; i++){
     scanf("%d",&a[i]);
}
   for(i=0; i<4; i++){
     scanf("%d",&b[i]);
}
    for(i=0;i<4;i++){
       if(a[i] == b[i])
           h++;
     j=(i+1)%4;
     k=(i+2)%4;
     l=(i+3)%4;
       if(a[i] == b[j]||a[i] == b[k]||a[i] == b[(l)%4]) 
           b++;
     }
     printf("%d %d\n",h,b);
}
     return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:9: error: conflicting types for 'b'; have 'int'
    7 |   int h,b;
      |         ^
main.c:5:7: note: previous declaration of 'b' with type 'int[4]'
    5 |   int b[4];
      |       ^
Language: C

#include <cstdio>

int main(){
	int a[4], b[4];
	while(~scanf("%d %d %d %d\n%d %d %d %d\n", &a[0], &a[1], &a[2], &a[3], &b[0], &b[1], &b[2], &b[3])){
		int hit = 0, blow = 0;
		for(int i = 0; i < 4; i++)
		for(int j = 0; j < 4; j++)
			if(a[i] == b[j])
				if(i == j) hit++; else blow++;
		printf("%d %d\n", hit, blow);
	}
	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 a[4], b[4];
	while(~scanf("%d %d %d %d\n%d %d %d %d\n", &a[0], &a[1], &a[2], &a[3], &b[0], &b[1], &b[2], &b[3])){
		int hit = 0, blow = 0;
		for(int i = 0; i < 4; i++){
            for(int j = 0; j < 4; j++){
                if(a[i] == b[j])
                    if(i == j){
                        hit++
                    }else{
                        blow++;
                    }
            }
        }
		printf("%d %d\n", hit, blow);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:11:30: error: expected ';' before '}' token
   11 |                         hit++
      |                              ^
      |                              ;
   12 |                     }else{
      |                     ~