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

#include <stdio.h>
#include <stdlib.h>
#define SIZE 64

/* prototype declaration */
void getTable(int *a);
char determinant();

int main(int argc, const char *argv[])
{
	while(1){
		printf("ans:%c\n", determinant());
	}	
	return 0;
}

char determinant()
{
	int a[SIZE], i; 
	
	getTable(a);
	
	for(i=0; a[i]==0; i++);

	if(a[i] && a[i+1] && a[i+2] && a[i+3]) return 'C';
	if(a[i] && a[i+1] && a[i+8] && a[i+9]) return 'A';
	if(a[i] && a[i+1] && a[i+9] && a[i+10]) return 'E';
	if(a[i] && a[i+1] && a[i+7] && a[i+8]) return 'G';
	if(a[i] && a[i+7] && a[i+8] && a[i+15]) return 'D';
	if(a[i] && a[i+8] && a[i+9] && a[i+17]) return 'F';
	if(a[i] && a[i+8] && a[i+16] && a[i+24]) return 'B';
	return -1;
}

void getTable(int *a)
{
	int i=0, ch;
	
	while(i<SIZE){
		ch = getchar();
		
		if(ch==EOF) exit(0);
		if(ch=='\n') continue;
		
		a[i] = ch-'0';
		i++;
	}		
	showTable(a);
}

Compiler output:
main.c: In function 'getTable':
main.c:48:9: error: implicit declaration of function 'showTable' [-Wimplicit-function-declaration]
   48 |         showTable(a);
      |         ^~~~~~~~~
Language: C++

#include<stdio.h>

int main(){
char a[8][8];
int ans = 0;
while(1){
for(int i = 0; i < 8; i++){
if(scanf("%s",&a[i]) == EOF){
return 0;
}
}

for(int i = 0; i < 8; i++){
for(int j = 0; j < 8; j++){
if(a[i][j] == 1){
if(i < 7 && j < 7){
if(a[i+1][j] == 1 && a[i][j+1] == 1 && a[i+1][j+1] == 1){
printf("A\n");
}
}
if(i < 5){
if(a[i+1][j] == 1 && a[i+2][j] == 1 && a[i+3][j] == 1){
printf("B\n");
}
}
if(j < 5){
if(a[i][j+1] == 1 && a[i][j+2] == 1 && a[i][j+3] == 1){
printf("C\n");
}
}
if(i < 6 && j < 5){
if(a[i][j+1] == 1 && a[i+1][j+1] == 1 && a[i+1][j+2] == 1){
printf("E\n");
}
}
if(i < 5 && j < 6){
if(a[i+1][j] == 1 && a[i+1][j+1] == 1 && a[i+2][j+1] == 1){
printf("F\n");
}
}
if(j > 0 && i < 6){
if(a[i+1][j] == 1 && a[i+1][j-1] == 1 && a[i+2][j-1] == 1){
printf("D\n");
}
}
if(j > 0 && j < 7 && i < 7){
if(a[i+1][j] == 1 && a[i][j+1] == 1 && a[i+1][j-1] == 1){
printf("G\n");
}
}
}
}
}
}
}
return 0;
}

Compiler output:
a.cc:56:1: error: expected unqualified-id before 'return'
   56 | return 0;
      | ^~~~~~
a.cc:57:1: error: expected declaration before '}' token
   57 | }
      | ^
Language: C++

#include <iostream>
#include <string>

using namespace std;

int main()
{

	while(1){
	
	char ret;
	string s;
	
	for(int i=0;i<8;i++){
		string s_tmp;
		if(scanf("%s", s) == EOF) return;
		s += s_tmp;
	}
	// 2次元配列を1次元的に処理
	for(int i=0;i<8*8;i++){
		if(s[i]=='1'){
			// Aかどうか
			if(s[i+1]=='1' && s[i+8]=='1' && s[i+9]=='1'){
				ret = 'A';
				break;
			}else if(s[i+8]=='1' && s[i+16]=='1' && s[i+24]=='1'){
				ret = 'B';
				break;
			}else if(s[i+1]=='1' && s[i+2]=='1' && s[i+3]=='1'){
				ret = 'C';
				break;
			}else if(s[i+7]=='1' && s[i+8]=='1' && s[i+15]=='1'){
				ret = 'D';
				break;
			}else if(s[i+1]=='1' && s[i+9]=='1' && s[i+10]=='1'){
				ret = 'E';
				break;
			}else if(s[i+8]=='1' && s[i+9]=='1' && s[i+17]=='1'){
				ret = 'F';
				break;
			}else if(s[i+1]=='1' && s[i+7]=='1' && s[i+8]=='1'){
				ret = 'G';
				break;
			}
		}
	}
	}
	cout<<ret<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:43: error: return-statement with no value, in function returning 'int' [-fpermissive]
   16 |                 if(scanf("%s", s) == EOF) return;
      |                                           ^~~~~~
a.cc:48:15: error: 'ret' was not declared in this scope
   48 |         cout<<ret<<endl;
      |               ^~~
Language: C++

00000000
00000000
01100000
00110000
00000000
00000000
00000000
00000000

00011110
00000000
00000000
00000000
00000000
00000000
00000000
00000000

00000000
00000000
00110000
00110000
00000000
00000000
00000000
00000000

Compiler output:
a.cc:1:1: error: expected unqualified-id before numeric constant
    1 | 00000000
      | ^~~~~~~~
Language: C++

#include<iostream>
using namespace std;
#define rep(i,a) for(int i = 0 ; i < a ; i ++)
int main(void){
  char maze[9][9];
  while(true){
    rep(i,8)rep(j,8)cin>>maze[i][j];
    if(cin.eof())break;
    bool used = false;
    rep(y,8){
      rep(x,8){
	if (board[y][x] == '1') {
	  if (board[y][x+1] == '1' && board[y+1][x] == '1' && board[y+1][x+1] == '1')
	    cout << "A" << endl;
	  else if (board[y+1][x] == '1' && board[y+2][x] == '1' && board[y+3][x] == '1')
	    cout << "B" << endl;
	  else if (board[y][x+1] == '1' && board[y][x+2] == '1' && board[y][x+3] == '1')
	    cout << "C" << endl;
	  else if (board[y+1][x] == '1' && board[y+1][x-1] == '1' && board[y+2][x-1] == '1')
	    cout << "D" << endl;
	  else if (board[y][x+1] == '1' && board[y+1][x+1] == '1' && board[y+1][x+2] == '1')
	    cout << "E" << endl;
	  else if (board[y+1][x] == '1' && board[y+1][x+1] == '1' && board[y+2][x+1] == '1')
	    cout << "F" << endl;
	  else
	    cout << "G" << endl;
	  used = true;
	}
	/*
	  if(maze[y][x]=='1'){
	  if(maze[ y ][x+1] == '1' && maze[y+1][ x ] =='1' &&
	  maze[y+1][x+1] =='1') cout << "A" << endl;
	  else if(maze[y+1][ x ] == '1' && maze[y+2][ x ] == '1' &&
	  maze[y+3][ x ] == '1') cout << "B" << endl;
	  else if(maze[ y ][x+3] == '1' && maze[y][x+2] == '1' &&
	  maze[ y ][x+1] == '1') cout << "C" << endl;
	  else if(maze[y+1][ x ] == '1' && maze[y+1][x-1] == '1' &&
	  maze[y+2][x-1] == '1') cout << "D" << endl;
	  else if(maze[ y ][x+1] == '1' && maze[y+1][x+1] == '1' &&
	  maze[y+1][x+2] == '1') cout << "E" << endl;
	  else if(maze[y+1][ x ] == '1' && maze[y+1][+1] == '1' &&
	  maze[y+2][x+1] == '1') cout << "F" << endl;
	  else cout << "G" << endl;
	  used = true;
	  }
	*/
	if(used)break;
      }
      if(used)break;
    }
  }

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:13: error: 'board' was not declared in this scope
   12 |         if (board[y][x] == '1') {
      |             ^~~~~
Language: C++

#include <iostream>
#include <cstdio>

using namespace std;

typedef struct _XY {
	int x;
	int y;
} XY;

XY figure[][4] = {
	{{1, 0}, {0, 1}, {1, 1}}, // A
	{{0, 1}, {0, 2}, {0, 3}}, // B
	{{1, 0}, {2, 0}, {3, 0}}, // C
	{{0, 1}, {-1, 1}, {-1, 2}}, // D
	{{1, 0}, {1, 1}, {2, 1}}, // E
	{{0, 1}, {1, 1}, {1, 2}}, // F
	{{1, 0}, {0, 1}, {-1, 1}}, // G
};

string name[7] = {"A", "B", "C", "D", "E", "F", "G"};
int main() {
	int math[8][8];
	char c;
	while (1) {
		memset(math, 0, sizeof(math));
		for (int i = 0; i < 8; i++) {
			for (int j = 0; j < 8; j++) {
				c = getchar();
				math[i][j] = c - '0';
			}
			c = getchar();
		}

//		for (int i = 0; i < 8; i++) {
//			for (int j = 0; j < 8; j++) {
//				cout << math[i][j];
//			}
//			cout << endl;
//		}

		XY p;
		for (int i = 0; i < 8; i++) {
			for (int j = 0; j < 8; j++) {
				if (math[i][j] == 1) {
					p.x = j;
					p.y = i;
					goto END;
				}
			}
		}

END:
		for (int i = 0; i < 7; i++) {
			if (math[p.y + figure[i][0].y][p.x + figure[i][0].x] == 1 &&
				math[p.y + figure[i][1].y][p.x + figure[i][1].x] == 1 &&
				math[p.y + figure[i][2].y][p.x + figure[i][2].x] == 1 ) {
				cout << name[i] << endl;
				break;
			}
		}

		c = getchar();
		if (c == EOF)
			break;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:26:17: error: 'memset' was not declared in this scope
   26 |                 memset(math, 0, sizeof(math));
      |                 ^~~~~~
a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    2 | #include <cstdio>
  +++ |+#include <cstring>
    3 |
Language: C++


#include<iostream>
#include<string>
#include<vector>
#include<cstdio>
#include<sstream>
#include<algorithm>
#include<cmath>
#include<map>
#include<functional>
#include<queue>
#include<stack>
#include<set>
using namespace std;
int stoi(string x){stringstream ss;ss<<x;int tmp;ss>>tmp;return tmp;}
string itos(int x){stringstream ss;ss<<x;return ss.str();}
char ta[12][12];

bool ok(int y,int x){
	if(y<0||x<0||y>7||x>7)return 0;
	if(ta[y][x]=='1')return 1;
	return 0;
}
int main(){

while(cin>>ta[0][0]){
	int y,x;
	bool f=1;
	for(int i=0;i<8;i++){
		for(int j=(i==0);j<8;j++){
			char now;
			cin>>now;
			if(now=='1'){
			y=i,x=j;
	if( ok(y,x+1)&ok(y+1,x)&&ok(y+1,x+1) ){cout<<"A";f=0;}
	
	else if( ok(y+1,x)&&ok(y+2,x)&&ok(y+3,x) ){cout<<"B";f=0;}
	
	else if( ok(y,x+1)&&ok(y,x+2)&&ok(y,x+3) ){cout<<"C";f=0;}
	
	else if( ok(y+2,x-1)&&ok(y+1,x-1)&&ok(y+1,x)){cout<<"C";f=0;}
	
	else if( ok(y,x+1)&ok(y+1,x+1)&&ok(y+1,x+2) ){cout<<"E";f=0;}
	
	else if( ok(y+1,x)&&ok(y+1,x+1) &&ok(y+2,x+1)){cout<<"F";f=0;}
	
	else if( ok(y,x+1)&&ok(y+1,x)&&ok(y+1,x-1) ){cout<<"G";f=0;}
	
	if(f==0){cout<<endl;goto end:;}
			}
			ta[i][j]=now;
		}
	}
	end:;
		for(int i=0;i<8;i++)for(int j=0;j<8;j++)ta[i][j]='0';
}
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:49:37: error: expected ';' before ':' token
   49 |         if(f==0){cout<<endl;goto end:;}
      |                                     ^
      |                                     ;
a.cc:49:37: error: expected primary-expression before ':' token
Language: C++

#include <algorithm>
#include <cmath>
#include <climits>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <iostream>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <vector>
#include <cassert>
#include <functional>

using namespace std;

#define LOG(...) printf(__VA_ARGS__)
//#define LOG(...)
#define FOR(i,a,b) for(int i=(int)(a);i<(int)(b);++i)
#define REP(i,n) for(int i=0;i<(int)(n);++i)
#define ALL(a) (a).begin(),(a).end()
#define RALL(a) (a).rbegin(),(a).rend()
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define SORT(c) sort((c).begin(),(c).end())
#define RSORT(c) sort((c).rbegin(),(c).rend())
#define CLR(a) memset((a), 0 ,sizeof(a))

typedef long long ll;
typedef unsigned long long ull;
typedef vector<bool> vb;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef vector<vb> vvb;
typedef vector<vi> vvi;
typedef vector<vll> vvll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;

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

int main() {
	bool br = false;
	while (true){
		bool cell[8][8] = { false };
		int ans = 0;
		REP(i, 8){
			string s;
			getline(cin, s);
			if (s.empty){
				br = true;
				break;
			}
			REP(j, 8){
				if (s[j] == '1')
					cell[i][j] = true;
			}
		}
		if (br)
			break;
		REP(i, 8){
			REP(j, 8){
				if (cell[i][j]){
					REP(k, 3)
						REP(l, 3)
						if (i + (k - 1) >= 0 && i + (k - 1) < 8 && j + (l - 1) >= 0 && j + (l - 1) < 8 && cell[i + (k - 1)][j + (l - 1)])
							ans += 1 << (8 - (k * 3 + l));
					i = 8;
					j = 8;
				}
			}
		}
		switch (ans){
		case 27:
			cout << 'A' << endl;
			break;
		case 18:
			cout << 'B' << endl;
			break;
		case 24:
			cout << 'C' << endl;
			break;
		case 22:
			cout << 'D' << endl;
			break;
		case 25:
			cout << 'E' << endl;
			break;
		case 19:
			cout << 'F' << endl;
			break;
		case 30:
			cout << 'G' << endl;
			break;
		}
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:54:36: error: cannot convert 'std::__cxx11::basic_string<char>::empty' from type 'bool (std::__cxx11::basic_string<char>::)() const noexcept' to type 'bool'
   54 |                         if (s.empty){
      |                                    ^
Language: C++

#include <iostream>
#include <cstdio>
#include <vector>
#include <string>
#include <map>
#include <algorithm>
#include <cmath>
#include <numeric>
#include <stack>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define For(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}

bool hasA(int bd[8][8]) {
    for (int i = 0; i < 7; i++) {
        for (int j = 0; j < 7; j++) {
            if (bd[i][j] && bd[i][j+1] && bd[i+1][j] && bd[i+1][j+1]) return true;
        }
    }
    return false;
}

bool hasB(int bd[8][8]) {
    for (int i = 0; i < 5; i++) {
        for (int j = 0; j < 8; j++) {
            if (bd[i][j] && bd[i+1][j] && bd[i+2][j] && bd[i+3][j]) return true;
        }
    }
    return false;
}

bool hasC(int bd[8][8]) {
    for (int i = 0; i < 8; i++) {
        for (int j = 0; j < 5; j++) {
            if (bd[i][j] && bd[i][j+1] && bd[i][j+2] && bd[i][j+3]) return true;
        }
    }
    return false;
}

bool hasD(int bd[8][8]) {
    for (int i = 0; i < 6; i++) {
        for (int j = 0; j < 7; j++) {
            if (bd[i][j+1] && bd[i+1][j] && bd[i+1][j+1] && bd[i+2][j]) return true;
        }
    }
    return false;
}

bool hasE(int bd[8][8]) {
    for (int i = 0; i < 7; i++) {
        for (int j = 0; j < 6; j++) {
            if (bd[i][j] && bd[i][j+1] && bd[i+1][j+1] && bd[i+1][j+2]) return true;
        }
    }
    return false;
}

bool hasF(int bd[8][8]) {
    for (int i = 0; i < 6; i++) {
        for (int j = 0; j < 7; j++) {
            if (bd[i][j] && bd[i+1][j] && bd[i+1][j+1] && bd[i+2][j+1]) return true;
        }
    }
    return false;
}

bool hasG(int bd[8][8]) {
    for (int i = 0; i < 7; i++) {
        for (int j = 0; j < 6; j++) {
            if (bd[i][j+1] && bd[i][j+2] && bd[i+1][j] && bd[i+1][j+1]) return true;
        }
    }
    return false;
}

int main36() {
    string s;
    int bd[8][8];
    while(cin >> s) {
        REP(i,8) bd[0][i] = s[i] - '0';
        REP(j,7) {
            cin >> s;
            REP(i,8) bd[j+1][i] = s[i] - '0';
        }
        // input ends
        if (hasA(bd)) cout << "A" << endl;
        else if (hasB(bd)) cout << "B" << endl;
        else if (hasC(bd)) cout << "C" << endl;
        else if (hasD(bd)) cout << "D" << endl;
        else if (hasE(bd)) cout << "E" << endl;
        else if (hasF(bd)) cout << "F" << endl;
        else if (hasG(bd)) cout << "G" << endl;
    }
    return 0;
}

Compiler output:
/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 <bits/stdc++.h>
using namespace std;

typedef complex<int> P;

namespace std{
	bool operator < (const P &a,const P &b){
		if( a.real() != b.real() ) return a.real() < b.real();
		return a.imag() < b.imag();
	}
	bool operator == (const P &a,const P &b){
		if( a.real() != b.real() ) return false;
		return a.imag() == b.imag();
	}
};

vector<vector<P>> ptn = {
	{P(0,0),P(1,1),P(1,0),P(0,1)},
	{P(0,0),P(0,2),P(0,1),p(0,3)},
	{P(0,0),P(1,0),P(2,0),P(3,0)},
	{P(1,0),P(1,1),P(0,1),P(0,2)},
	{P(0,0),P(1,0),P(1,1),P(2,1)},
	{P(0,0),P(0,1),P(1,1),P(1,2)},
	{P(1,0),P(2,0),P(0,1),P(1,1)}
};

string s[8];
int main(){
	while(true){
		for(int i = 0 ; i < 8 ; i++){
			if(!(cin >> s[i]))exit(0);
			
		}
		for(int i = 0 ; i < 7 ; i++)
			sort(ptn[i].begin(),ptn[i].end());
		for(int i = -10 ; i <= 10 ; i++)
			for(int j = -10 ; j <= 10 ; j++){
				vector<P> tmp;
				for(int y = 0 ; y < 8 ; y++)
					for(int x = 0 ; x < 8 ; x++){
						if( s[y][x] == '1'){
							tmp.push_back(P(x-j,y-i));
						}
					}
				sort(tmp.begin(),tmp.end());
				for(int k = 0 ; k < 7 ; k++){
					if( tmp == ptn[k] ){
						cout << (char)(k+'A') << endl;
					}
				}
			}
	}
					
					
	
	
}

Compiler output:
a.cc:19:31: error: 'p' was not declared in this scope
   19 |         {P(0,0),P(0,2),P(0,1),p(0,3)},
      |                               ^
a.cc:25:1: error: could not convert '{{std::complex<int>(0, 0), std::complex<int>(1, 1), std::complex<int>(1, 0), std::complex<int>(0, 1)}, {std::complex<int>(0, 0), std::complex<int>(0, 2), std::complex<int>(0, 1), <expression error>}, {std::complex<int>(0, 0), std::complex<int>(1, 0), std::complex<int>(2, 0), std::complex<int>(3, 0)}, {std::complex<int>(1, 0), std::complex<int>(1, 1), std::complex<int>(0, 1), std::complex<int>(0, 2)}, {std::complex<int>(0, 0), std::complex<int>(1, 0), std::complex<int>(1, 1), std::complex<int>(2, 1)}, {std::complex<int>(0, 0), std::complex<int>(0, 1), std::complex<int>(1, 1), std::complex<int>(1, 2)}, {std::complex<int>(1, 0), std::complex<int>(2, 0), std::complex<int>(0, 1), std::complex<int>(1, 1)}}' from '<brace-enclosed initializer list>' to 'std::vector<std::vector<std::complex<int> > >'
   25 | };
      | ^
      | |
      | <brace-enclosed initializer list>
Language: C++

#include<iostream>
#include<algorithm>
using namespace std;
int main() {
	while (!cin.eof) {
		char c[8][8];
		for (int i = 0; i < 8; i++)
			for (int j = 0; j < 8; j++)
				cin >> c[i][j];
		int a, b;
		for (int i = 0; i < 8; i++) {
			for (int j = 0; j < 8; j++) {
				if (c[i][j] == '1') {
					a = i;
					b = j;
					goto C;
				}
			}
		}
	C:
		if (c[a][b + 1] == '1') 
			if (c[a + 1][b] == '1') 
				if (c[a + 1][b + 1] == '1')
					cout << 'A';
				else cout << 'G';
			else
				if (c[a + 1][b + 1] == '1')
					cout << 'E';
				else cout << 'C';
		else if (c[a + 1][b + 1] == '1')
			cout << 'F';
		else if (c[a - 1][b + 1] == '1')
			cout << 'D';
		else cout << 'C';
		cout << endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:21: error: cannot convert 'std::basic_ios<char>::eof' from type 'bool (std::basic_ios<char>::)() const' to type 'bool'
    5 |         while (!cin.eof) {
      |                     ^~~
a.cc:5:21: error: in argument to unary !
    5 |         while (!cin.eof) {
      |                 ~~~~^~~
Language: C++

import java.util.Scanner;

public class Main {
	private Scanner sc;
	
	public static void main(String[] args) {
		new Main_format();
	}
	
	public Main() {
		sc = new Scanner(System.in);
		
		while (sc.hasNext() == true) {
			int[][] map = new int[8][8];

			for (int i = 0; i < 8; i++) {
				String line = sc.nextLine();
				
				for (int j = 0; j < 8; j++) {
					map[i][j] = line.charAt(j) - '0';
				}
			}
			
			int state = 0;
			int max = 8;
			int k = 0;
			
			boolean end = false;
			for (int i = 0; i < max; i++) {
				for (int j = k; j < 8; j++) {
					if (map[i][j] == 1) {
						switch (state) {
						case 0:
							state = 1;
							max = i + 4;
							k = j - 1;
							break;
							
						case 1:
							state = 2;
							break;

						case 2:
							state = 3;
							break;

						case 3:
							System.out.println("C");
							end = true;
							break;
						
						case 4:
							if (j == k) {
								System.out.println("D");
								end = true;
							} else {
								state = 6;
							}
							break;
							
						case 5:
							if (j == k) {
								System.out.println("G");
								end = true;
							} else if (j == (k + 1)) {
								System.out.println("A");
								end = true;
							} else {
								System.out.println("E");
								end = true;
							}
								
						case 6:
							System.out.println("F");
							end = true;
							break;
						}
						
					}
					if (end == true) break;
				}
				
				if ((state == 1) || (state == 2)) {
					state = state + 3;
				} if (state == 6) {
					System.out.println("B");
					end = true;
				}
				if (end == true) break;
 			}
		}
	}
}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.Scanner;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
    3 | public class Main {
      | ^~~~~~
Language: C++

import java.util.Scanner;

public class Main {

	static Scanner sc = new java.util.Scanner(System.in);

	// static int[][] num =new int [8][8];

	public static void main(String[] args) {

		int[][] num = new int[15][15];
		String str = "";

		while (sc.hasNextLine()) {
			// num[][]????????????
			syokika(num);
			// ???????????¨????????????????´?
			for (int i = 0; i < 8; i++) {
				str = sc.next();
				String[] st = str.split("");
				for (int j = 0; j < 8; j++) {
					num[i][j] = Integer.parseInt(st[j]);
				}
			}
			// ????????????
			for (int i = 0; i < 8; i++) {
				for (int j = 0; j < 8; j++) {
					if(num[i][j]==1&&num[i][j+1]==1&&num[i+1][j]==1&&num[i+1][j+1]==1){
						System.out.println("A");
					}else if(num[i][j]==1&&num[i+1][j]==1&&num[i+2][j]==1&&num[i+3][j]==1){
						System.out.println("B");
					}else if(num[i][j]==1&&num[i][j+1]==1&&num[i][j+2]==1&&num[i][j+3]==1){
						System.out.println("C");
					}else if(num[i][j+1]==1&&num[i+1][j]==1&&num[i][j+1]==1&&num[i+2][j]==1){
						System.out.println("D");
					}else if(num[i][j]==1&&num[i][j+1]==1&&num[i+1][j+1]==1&&num[i+1][j+2]==1){
						System.out.println("E");
					}else if(num[i][j]==1&&num[i+1][j]==1&&num[i+1][j+1]==1&&num[i+2][j+1]==1){
						System.out.println("F");
					}else if(num[i][j+1]==1&&num[i][j+2]==1&&num[i+1][j]==1&&num[i+1][j+1]==1){
						System.out.println("B");
					}

				}
			}

		}

	}
}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.Scanner;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
    3 | public class Main {
      | ^~~~~~
Language: C++

import java.util.Scanner;

public class Main {

	static Scanner sc = new java.util.Scanner(System.in);

	// static int[][] num =new int [8][8];

	public static void main(String[] args) {

		int[][] num = new int[15][15];
		String str = "";

		while (sc.hasNextLine()) {
			// num[][]????????????
			syokika(num);
			// ???????????¨????????????????´?
			for (int i = 0; i < 8; i++) {
				str = sc.next();
				String[] st = str.split("");
				for (int j = 0; j < 8; j++) {
					num[i][j] = Integer.parseInt(st[j]);
				}
			}
			// ????????????
			for (int i = 0; i < 8; i++) {
				for (int j = 0; j < 8; j++) {
					if (num[i][j] == 1 && num[i][j + 1] == 1 && num[i + 1][j] == 1 && num[i + 1][j + 1] == 1) {
						System.out.println("A");
					} else if (num[i][j] == 1 && num[i + 1][j] == 1 && num[i + 2][j] == 1 && num[i + 3][j] == 1) {
						System.out.println("B");
					} else if (num[i][j] == 1 && num[i][j + 1] == 1 && num[i][j + 2] == 1 && num[i][j + 3] == 1) {
						System.out.println("C");
					} else if (num[i][j + 1] == 1 && num[i + 1][j] == 1 && num[i][j + 1] == 1 && num[i + 2][j] == 1) {
						System.out.println("D");
					} else if (num[i][j] == 1 && num[i][j + 1] == 1 && num[i + 1][j + 1] == 1
							&& num[i + 1][j + 2] == 1) {
						System.out.println("E");
					} else if (num[i][j] == 1 && num[i + 1][j] == 1 && num[i + 1][j + 1] == 1
							&& num[i + 2][j + 1] == 1) {
						System.out.println("F");
					} else if (num[i][j + 1] == 1 && num[i][j + 2] == 1 && num[i + 1][j] == 1
							&& num[i + 1][j + 1] == 1) {
						System.out.println("B");
					}

				}
			}

		}

	}

	// ???????????¢??°
	public static int[][] syokika(int[][] num) {

		for (int i = 0; i < 8; i++) {
			for (int j = 0; j < 8; j++) {
				num[i][j] = 0;
			}
		}
		return num;
	}

}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.Scanner;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
    3 | public class Main {
      | ^~~~~~
Language: C++

#include<iostream>
#include<cstdio>
#include<string>
#include<algorithm>
#include<math.h>
#include<bitset>
using namespace std;
int main(){
	int a,b;
	char map[64];
	int movex[4]={1,0,-1,0},movey[4]={0,1,0,-1};
	while(cin>>map[0]){
		for(int i=1;i<64;i++){
			cin>>map[i];
		}
		int i,j;
		for(i=0;i<64;i++){
			if(map[i]=='1'){
				break;
			}
		}
		if(map[i+1]=='1'){
			if(map[i+8]=='1'&&map[i+9]=='1'){
				cout<<"A"<<endl;
			}
			else if(map[i+2]=='1'&&map[i+3]=='1'){
				cout<<"C"<<endl;
			}
			else if(map[i+9]=='1'&&map[i+10]=='1'){
				cout<<"E"<<endl;
			}
			else if(map[i+7]=='1'&&map[i+8]=='1'){
				cout<<"G"<<endl;
			}
		}
		else if(map[i+8]=='1'){
			if(map[i+16]=='1'&&map[i+24]=='1'){
				cout<<"B"<<endl;
			}
			else if(map[i+7]=='1'&&map[i+15]){
				cout<<"D"<<endl;
			}
			else if(map[i+9]=='1'&&map[i+17]=='1'){
				cout<<"F"<<endl;
			}
		}
		memset(map,'0',sizeof(map));
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:47:17: error: 'memset' was not declared in this scope
   47 |                 memset(map,'0',sizeof(map));
      |                 ^~~~~~
a.cc:7:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    6 | #include<bitset>
  +++ |+#include <cstring>
    7 | using namespace std;
Language: C++

#include<bits/c++std.h>
#include<iostream>
#include<cstdio>
#include<string>
#include<algorithm>
#include<math.h>
#include<bitset>
using namespace std;
int main(){
	int a,b;
	char map[64];
	int movex[4]={1,0,-1,0},movey[4]={0,1,0,-1};
	while(cin>>map[0]){
		for(int i=1;i<64;i++){
			cin>>map[i];
		}
		int i,j;
		for(i=0;i<64;i++){
			if(map[i]=='1'){
				break;
			}
		}
		if(map[i+1]=='1'){
			if(map[i+8]=='1'&&map[i+9]=='1'){
				cout<<"A"<<endl;
			}
			else if(map[i+2]=='1'&&map[i+3]=='1'){
				cout<<"C"<<endl;
			}
			else if(map[i+9]=='1'&&map[i+10]=='1'){
				cout<<"E"<<endl;
			}
			else if(map[i+7]=='1'&&map[i+8]=='1'){
				cout<<"G"<<endl;
			}
		}
		else if(map[i+8]=='1'){
			if(map[i+16]=='1'&&map[i+24]=='1'){
				cout<<"B"<<endl;
			}
			else if(map[i+7]=='1'&&map[i+15]){
				cout<<"D"<<endl;
			}
			else if(map[i+9]=='1'&&map[i+17]=='1'){
				cout<<"F"<<endl;
			}
		}
		memset(map,'0',sizeof(map));
	}
	return 0;
}

Compiler output:
a.cc:1:9: fatal error: bits/c++std.h: No such file or directory
    1 | #include<bits/c++std.h>
      |         ^~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<iostream>
using namespace std;
int main() {
	char c[10][10];
    while (cin>>c[0][0]){
        for (int i = 0; i < 8; i++)
            for (int j = 0; j < 8; j++)
                if(!i&&!j)continue;
                cin >> c[i][j];
        int a, b;
        for (int i = 0; i < 8; i++) {
            for (int j = 0; j < 8; j++) {
                if (c[i][j] == '1') {
                    a = i;
                    b = j;
                    goto C;
                }
            }
        }
    C:
        if (c[a][b + 1] == '1') {
            if (c[a + 1][b] == '1') {
                if (c[a + 1][b + 1] == '1')
                    cout << 'A';
                else cout << 'G';
            }
            else {
                if (c[a + 1][b + 1] == '1')
                    cout << 'E';
                else cout << 'C';
            }
        }
        else if (c[a + 1][b + 1] == '1')
            cout << 'F';
        else if (c[a + 1][b - 1] == '1')
            cout << 'D';
        else cout << 'B';
        cout << endl;
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:26: error: 'i' was not declared in this scope
    9 |                 cin >> c[i][j];
      |                          ^
a.cc:9:29: error: 'j' was not declared in this scope
    9 |                 cin >> c[i][j];
      |                             ^
Language: C++

#include<iostream>
using namespace std;
int main() {
	char c[10][10];
    while (cin>>c[0][0]){
        for (int i = 0; i < 8; i++)
            for (int j = 0; j < 8; j++)
                if(i==0&&j==0)continue;
                cin >> c[i][j];
        int a, b;
        for (int i = 0; i < 8; i++) {
            for (int j = 0; j < 8; j++) {
                if (c[i][j] == '1') {
                    a = i;
                    b = j;
                    goto C;
                }
            }
        }
    C:
        if (c[a][b + 1] == '1') {
            if (c[a + 1][b] == '1') {
                if (c[a + 1][b + 1] == '1')
                    cout << 'A';
                else cout << 'G';
            }
            else {
                if (c[a + 1][b + 1] == '1')
                    cout << 'E';
                else cout << 'C';
            }
        }
        else if (c[a + 1][b + 1] == '1')
            cout << 'F';
        else if (c[a + 1][b - 1] == '1')
            cout << 'D';
        else cout << 'B';
        cout << endl;
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:26: error: 'i' was not declared in this scope
    9 |                 cin >> c[i][j];
      |                          ^
a.cc:9:29: error: 'j' was not declared in this scope
    9 |                 cin >> c[i][j];
      |                             ^
Language: C++

input_lines = int(input())
for i in range(input_lines):
  s = i
 
#for i range 8:
    

print (s)


Compiler output:
a.cc:5:2: error: invalid preprocessing directive #for
    5 | #for i range 8:
      |  ^~~
a.cc:1:1: error: 'input_lines' does not name a type
    1 | input_lines = int(input())
      | ^~~~~~~~~~~
Language: C++

#include <iostream>
main(){int b[5][4],s,t,x,y;char l[8];for(;;){for(int i=0;i<20;i++)b[i%5][i/5]=0;sx=sy=9;for(y=0;y<8;y++){if(!(std::cin>>l))break;for(x=0;x<8;x++){if(l[x]=='1'){if(t==9){s=x-1;t=y;}b[x-s][y-t]=1;}}}if (y<8)break;char a='A';if(b[1][3])a='B';if(b[4][0])a='C';if(b[0][2])a='D';if(b[3][1])a='E';if(b[2][2])a='F';if(b[0][1]&&b[2][0])a='G';std::cout<<a<<"\n";}}

Compiler output:
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    2 | main(){int b[5][4],s,t,x,y;char l[8];for(;;){for(int i=0;i<20;i++)b[i%5][i/5]=0;sx=sy=9;for(y=0;y<8;y++){if(!(std::cin>>l))break;for(x=0;x<8;x++){if(l[x]=='1'){if(t==9){s=x-1;t=y;}b[x-s][y-t]=1;}}}if (y<8)break;char a='A';if(b[1][3])a='B';if(b[4][0])a='C';if(b[0][2])a='D';if(b[3][1])a='E';if(b[2][2])a='F';if(b[0][1]&&b[2][0])a='G';std::cout<<a<<"\n";}}
      | ^~~~
a.cc: In function 'int main()':
a.cc:2:81: error: 'sx' was not declared in this scope; did you mean 'x'?
    2 | main(){int b[5][4],s,t,x,y;char l[8];for(;;){for(int i=0;i<20;i++)b[i%5][i/5]=0;sx=sy=9;for(y=0;y<8;y++){if(!(std::cin>>l))break;for(x=0;x<8;x++){if(l[x]=='1'){if(t==9){s=x-1;t=y;}b[x-s][y-t]=1;}}}if (y<8)break;char a='A';if(b[1][3])a='B';if(b[4][0])a='C';if(b[0][2])a='D';if(b[3][1])a='E';if(b[2][2])a='F';if(b[0][1]&&b[2][0])a='G';std::cout<<a<<"\n";}}
      |                                                                                 ^~
      |                                                                                 x
a.cc:2:84: error: 'sy' was not declared in this scope; did you mean 'y'?
    2 | main(){int b[5][4],s,t,x,y;char l[8];for(;;){for(int i=0;i<20;i++)b[i%5][i/5]=0;sx=sy=9;for(y=0;y<8;y++){if(!(std::cin>>l))break;for(x=0;x<8;x++){if(l[x]=='1'){if(t==9){s=x-1;t=y;}b[x-s][y-t]=1;}}}if (y<8)break;char a='A';if(b[1][3])a='B';if(b[4][0])a='C';if(b[0][2])a='D';if(b[3][1])a='E';if(b[2][2])a='F';if(b[0][1]&&b[2][0])a='G';std::cout<<a<<"\n";}}
      |                                                                                    ^~
      |                                                                                    y
Language: C++

import java.util.*;
import java.lang.*;
import java.math.*;
import java.io.*;

import static java.lang.Math.*;
import static java.util.Arrays.*;

public class Main{

	Scanner sc;

	static final int INF=1<<28;
	static final double EPS=1e-9;

	class B{
		int[][] a;
		String name;

		B(int[][] a, String name){
			this.a=a;
			this.name=name;
		}
	}

	int[][] A={{1, 1}, {1, 1}};
	int[][] B={{1}, {1}, {1}, {1}};
	int[][] C={{1, 1, 1, 1}};
	int[][] D={{0, 1}, {1, 1}, {1, 0}};
	int[][] E={{1, 1, 0}, {0, 1, 1}};
	int[][] F={{1, 0}, {1, 1}, {0, 1}};
	int[][] G={{0, 1, 1}, {1, 1, 0}};

	int[][] field;

	int n=8;

	void run(){
		LinkedList<B> blocks=new LinkedList<B>();
		blocks.add(new B(A, "A"));
		blocks.add(new B(B, "B"));
		blocks.add(new B(C, "C"));
		blocks.add(new B(D, "D"));
		blocks.add(new B(E, "E"));
		blocks.add(new B(F, "F"));
		blocks.add(new B(G, "G"));

		sc=new Scanner(System.in);
		for(; sc.hasNext();){
			field=new int[n][n];
			for(int j=0; j<n; j++){
				String s=sc.nextLine();
				for(int i=0; i<n; i++){
					if(s.charAt(i)=='0')
						field[j][i]=0;
					else
						field[j][i]=1;
				}
			}
			boolean f=false;
			for(int j=0; j<n; j++){
				for(int i=0; i<n; i++){
					for(B b : blocks){
						if(match(b, i, j)){
							println(b.name);
							f=true;
							break;
						}
					}
					if(f)
						break;
				}
				if(f)
					break;
			}

			sc.nextLine();
		}
		sc.close();
	}

	boolean match(B b, int x, int y){
		int[][] a=b.a;
		for(int j=0; j<a.length; j++){
			for(int i=0; i<a[0].length; i++){
				int x2=x+i;
				int y2=y+j;
				if(x2<0||x2>=n||y2<0||y2>=n)
					return false;
				if(a[j][i]==1&&field[y2][x2]==0)
					return false;
			}
		}
		return true;
	}

	void print(String s){
		System.out.print(s);
	}

	void println(String s){
		System.out.println(s);
	}

	public static void main(String[] args){
		new Main().run();
	}
}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.*;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:2:1: error: 'import' does not name a type
    2 | import java.lang.*;
      | ^~~~~~
a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: 'import' does not name a type
    3 | import java.math.*;
      | ^~~~~~
a.cc:3:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:4:1: error: 'import' does not name a type
    4 | import java.io.*;
      | ^~~~~~
a.cc:4:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:6:1: error: 'import' does not name a type
    6 | import static java.lang.Math.*;
      | ^~~~~~
a.cc:6:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:7:1: error: 'import' does not name a type
    7 | import static java.util.Arrays.*;
      | ^~~~~~
a.cc:7:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:9:1: error: expected unqualified-id before 'public'
    9 | public class Main{
      | ^~~~~~
Language: C++

pln[14][14];
main(i,j,c,f){
	while(1){
		for(i=3;i<11;i++){
			for(j=3;j<11;j++)	pln[i][j]=getchar();
			if(getchar()==-1)	exit(0);
		}
		for(i=3;i<11;i++)for(j=3;j<11;j++)pln[i][j]-='0';
		getchar();

		f=1;
		for(i=3;f&&i<11;i++)for(j=3;f&&j<11;j++)
			if(pln[i][j]){
				if     (pln[i+3][j])	c='B';
				else if(pln[i][j+3])	c='C';
				else if(pln[i+2][j-1])	c='D';
				else if(pln[i+1][j+2])	c='E';
				else if(pln[i+2][j+1])	c='F';
				else if(!pln[i+1][j+1])	c='G';
				else	c='A';
				f=0;
			}
		printf("%c\n",c);
	}
}

Compiler output:
a.cc:1:1: error: 'pln' does not name a type
    1 | pln[14][14];
      | ^~~
a.cc:2:5: error: expected constructor, destructor, or type conversion before '(' token
    2 | main(i,j,c,f){
      |     ^
Language: C++

#include<stdio.h>

char mas[20][20]={0};

char check(x,y){
  if(mas[y][x+3]=='1'){
    //printf("C\n");
    return 'C';
  }
  if(mas[y+2][x+1]=='1'){
    //printf("F\n");
    return 'F';
  }
  
  if(x>0){
    if(mas[y+2][x-1]=='1'){
      //printf("D\n");
      return 'D';
    }
  }
  

  if(mas[y+3][x]=='1'){
    //printf("B\n");
    return 'B';
  }

  if(mas[y][x+1]=='1'){
    if(mas[y+1][x+2]=='1'){
      //printf("E\n");
      return 'E';
    }
    if(x>0){
      if(mas[y+1][x-1]=='1'){
	//printf("G\n");
	return 'G';
      }
    }
    if(mas[y+1][x]=='1'){
      //printf("A\n");
      return 'A';
    }
  }
  // printf("NA");
}

main(){
  int i,j;
  int f,x,y;
  char ans;
  while(scanf("%s",mas[0])!=EOF){

    f=0;

    for(j=0;j<8;j++){
      if(mas[0][j]=='1' && f==0){
	x=j;
	y=0;
	f=1;
      }
    }

    for(i=1;i<8;i++){
      scanf("%s",mas[i]);
      for(j=0;j<8;j++){
	if(mas[i][j]=='1' && f==0){
	  x=j;
	  y=i;
	  f=1;
	}
      }
    }
    printf("%c\n",check(x,y));
  }
  return 0;
}

Compiler output:
a.cc:5:12: error: 'x' was not declared in this scope
    5 | char check(x,y){
      |            ^
a.cc:5:14: error: 'y' was not declared in this scope
    5 | char check(x,y){
      |              ^
a.cc:5:15: error: expression list treated as compound expression in initializer [-fpermissive]
    5 | char check(x,y){
      |               ^
a.cc:47:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
   47 | main(){
      | ^~~~
a.cc: In function 'int main()':
a.cc:73:24: error: 'check' cannot be used as a function
   73 |     printf("%c\n",check(x,y));
      |                   ~~~~~^~~~~
Language: C++

#include<iostream>
using namespace std;
typedef unsigned __int64 ull;
int main(){
	int shape[7]={0x0303,0x01010101,0x0f,
		0x010302,0x0603,0x020301,0x0306};
	while(!cin.eof()){
		int ans=-1;
		ull mass=0;	
		for(int i=0;i<64;i++){
			char c;
			cin>>c;
			if(c=='1')mass |= (ull)1<<i; 
		}
		for(int i=0;i<64;i++){
			for(int j=0;j<7;j++){
				if((mass>>i&shape[j])==shape[j])ans=j;
			}
		}
		cout<<(char)(ans+'A')<<endl;
	}
	return 0;
}

Compiler output:
a.cc:3:26: error: expected initializer before 'ull'
    3 | typedef unsigned __int64 ull;
      |                          ^~~
a.cc: In function 'int main()':
a.cc:9:17: error: 'ull' was not declared in this scope
    9 |                 ull mass=0;
      |                 ^~~
a.cc:13:35: error: 'mass' was not declared in this scope
   13 |                         if(c=='1')mass |= (ull)1<<i;
      |                                   ^~~~
a.cc:17:37: error: 'mass' was not declared in this scope
   17 |                                 if((mass>>i&shape[j])==shape[j])ans=j;
      |                                     ^~~~
Language: C++

#include <iostream>

#define rep(i,n) for(int i=0; i<n; i++)

using namespace std;

int main() {
	char a, c;
	int map[10][10];

	while(cin >> c) {
		if(c == '0' || c== '1') {
			rep(i,10)rep(j,10)
				map[i][j] = 0;

			rep(i,8)rep(j,8) {
				if(!(i + j == 0)) ifs >> c;
				map[i][j] = (int)(c - '0');
			}

			rep(i,8)rep(j,8) {
				if(map[i][j]) {
					if(map[i][j+2])   a = 'C';
					if(map[i+2][j])   a = 'B';
					if(map[i+1][j+1]) a = 'A';
					if(map[i+1][j-1]) a = 'G';
					if(map[i+1][j+2]) a = 'E';
					if(map[i+2][j+1]) a = 'F';
					if(map[i+2][j-1]) a = 'D';
					break;
				}
			}

			cout << a << endl;
		}
	}

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:17:51: error: 'ifs' was not declared in this scope
   17 |                                 if(!(i + j == 0)) ifs >> c;
      |                                                   ^~~
Language: C++

#include <iostream>
#include <vector>
#include <stdio.h>
using namespace std;
int main() {
  char c[11][11];
  vector<int> v;
  int dat[7][6]={{1,1,1,1,0,0},{1,0,1,0,1,0},{1,1,0,0,0,0},{1,0,1,0,0,0},{1,1,0,1,0,0},
  {1,0,1,1,0,1},{1,1,1,0,0,0}};
  int i,j,k,x,y,f;
  while(true) {
      f=0;
	  for (i=0;i<8;i++) {
		  if (gets(c[i])==NULL) { i=10; break;}
		  if (f==0) for (j=0;j<8;j++) if (c[i][j]=='1') { f=1; x=j; y=i; j=9;}
	  }
	  if (i==10) break;
	  cout << endl;
	  for (k=0;k<7;k++) {
		  f=0;
		  for (i=0;i<3;i++) for (j=0;j<2;j++) {
			  if (x+j>7 || y+i>7) { if (dat[k][j+i*2]==0) f++;}  else
				  if (c[y+i][x+j]==('0'+dat[k][j+i*2])) f++;
		  }
		  if (f==6) break;
	  }
	  v.push_back(k);
  }
  for (i=0;i<v.size();i++) cout << (char)('A'+v[i]) << endl;
  return 0

Compiler output:
a.cc: In function 'int main()':
a.cc:14:23: error: 'gets' was not declared in this scope; did you mean 'getw'?
   14 |                   if (gets(c[i])==NULL) { i=10; break;}
      |                       ^~~~
      |                       getw
a.cc:30:11: error: expected ';' at end of input
   30 |   return 0
      |           ^
      |           ;
a.cc:30:11: error: expected '}' at end of input
a.cc:5:12: note: to match this '{'
    5 | int main() {
      |            ^
Language: C++

#include<iostream>
#include<string>

using namespace std;
int main(){
	
	while(1){
	string str[8];
	for(int i =0;i<8;i++)
		cin >> str[i];
	
	bool stop = false;
	for(int i=0;i<8;i++){
	for(int k=0;k<8;k++){
	if(str[i][k] == '1'){
		if(str[i][k+1] == '1' && str[i+1][k+1] == '1'&& str[i+1][k] == '1' ){
		cout << "A" << endl;  stop = true; break;
		} else if(str[i+1][k] == '1' && str[i+2][k] == '1'&& str[i+3][k] == '1' ){
		cout << "B" << endl; stop = true; break;
		} else if(str[i][k+1] == '1' && str[i][k+2] == '1'&& str[i][k+3] == '1' ){
		cout << "C" << endl;  stop = true; break;
		} else if(str[i+1][k] == '1' && str[i+1][k-1] == '1'&& str[i+2][k-1] == '1' ){
		cout << "D" << endl;  stop = true; break;
		} else if(str[i][k+1] == '1' && str[i+1][k+1] == '1'&& str[i+1][k+2] == '1' ){
		cout << "E" << endl;  stop = true; break;
		} else if(str[i+1][k] == '1' && str[i+1][k+1] == '1'&& str[i+2][k+1] == '1' ){
		cout << "F" << endl;  stop = true; break;
		} else if(str[i][k+1] == '1' && str[i+1][k] == '1'&& str[i+1][k-1] == '1' ){
		cout << "G" << endl;  stop = true; break;
		}
	
	}
	
	}
	if(stop == true) break;
	}
	if (!getline(cin, str[0]))
    break;
	
	}
	

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

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

int main(){
	int mass[8][8];
	
	BEGIN:
	while(scanf("%d%d%d%d%d%d%d%d",mass[0],mass[0]+1,mass[0]+2,mass[0]+3,mass[0]+4
	mass[0]+5,mass[0]+6,mass[0]+7)!=EOF)
	{
		for(int i=1;i<8;i++){
			scanf("%d%d%d%d%d%d%d%d",mass[i],mass[i]+1,mass[i]+2,mass[i]+3,mass[i]+4
				mass[i]+5,mass[i]+6,mass[i]+7);
		}
		for(int i=0;i<8;i++){
			for(int j=0;j<8;j++){
				if(mass[i][j]){
					if(j==7){
						if(mass[i+1][j]){
							cout<<(mass[i+1][j-1]?"D\n":"B\n");
						}
					}else if(j==0){
						if(mass[i][j+1]){
							if(mass[i+1][j]) cout<<"A\n";
							else if(mass[i][j+2]) cout<<"C\n";
							else cout<<"E\n";
						}
						else cout<<(mass[i+1][j+1]?"F\n":"B\n");
					}else{
						if(mass[i][j+2]) cout<<"C\n";
						else if(mass[i][j+1]){
							if(mass[i+1][j]){
								cout<<(mass[i+1][j+1]?"A\n":"G\n");
							}
							else cout<<"E\n";
						}
						else if(mass[i+2][j]) cout<<"B\n";
						else cout<<(mass[i+1][j+1]?"F\n":"D\n");
					}
					goto BEGIN;
				}
			}
		}
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:87: error: expected ')' before 'mass'
    9 |         while(scanf("%d%d%d%d%d%d%d%d",mass[0],mass[0]+1,mass[0]+2,mass[0]+3,mass[0]+4
      |                    ~                                                                  ^
      |                                                                                       )
   10 |         mass[0]+5,mass[0]+6,mass[0]+7)!=EOF)
      |         ~~~~                                                                           
a.cc:13:97: error: expected ')' before 'mass'
   13 |                         scanf("%d%d%d%d%d%d%d%d",mass[i],mass[i]+1,mass[i]+2,mass[i]+3,mass[i]+4
      |                              ~                                                                  ^
      |                                                                                                 )
   14 |                                 mass[i]+5,mass[i]+6,mass[i]+7);
      |                                 ~~~~
Language: C++

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

int main(){
	int mass[8][8];
	
	BEGIN:
	while(scanf("%d%d%d%d%d%d%d%d",(*mass[0]),(*mass[0])+1,(*mass[0])+2,(*mass[0])+3,(*mass[0])+4
		(*mass[0])+5,(*mass[0])+6,(*mass[0])+7)!=EOF)
	{
		for(int i=1;i<8;i++){
			scanf("%d%d%d%d%d%d%d%d",(*mass[i]),(*mass[i]+1),(*mass[i]+2),(*mass[i]+3),(*mass[i]+4)
				(*mass[i]+5),(*mass[i]+6),(*mass[i]+7));
		}
		for(int i=0;i<8;i++){
			for(int j=0;j<8;j++){
				if(mass[i][j]){
					if(j==7){
						if(mass[i+1][j]){
							cout<<(mass[i+1][j-1]?"D\n":"B\n");
						}
					}else if(j==0){
						if(mass[i][j+1]){
							if(mass[i+1][j]) cout<<"A\n";
							else if(mass[i][j+2]) cout<<"C\n";
							else cout<<"E\n";
						}
						else cout<<(mass[i+1][j+1]?"F\n":"B\n");
					}else{
						if(mass[i][j+2]) cout<<"C\n";
						else if(mass[i][j+1]){
							if(mass[i+1][j]){
								cout<<(mass[i+1][j+1]?"A\n":"G\n");
							}
							else cout<<"E\n";
						}
						else if(mass[i+2][j]) cout<<"B\n";
						else cout<<(mass[i+1][j+1]?"F\n":"D\n");
					}
					goto BEGIN;
				}
			}
		}
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:17: error: expression cannot be used as a function
    9 |         while(scanf("%d%d%d%d%d%d%d%d",(*mass[0]),(*mass[0])+1,(*mass[0])+2,(*mass[0])+3,(*mass[0])+4
      |                                                                                                     ~
   10 |                 (*mass[0])+5,(*mass[0])+6,(*mass[0])+7)!=EOF)
      |                 ^~~~~~~~~~
a.cc:14:33: error: expression cannot be used as a function
   13 |                         scanf("%d%d%d%d%d%d%d%d",(*mass[i]),(*mass[i]+1),(*mass[i]+2),(*mass[i]+3),(*mass[i]+4)
      |                                                                                                    ~~~~~~~~~~~~
   14 |                                 (*mass[i]+5),(*mass[i]+6),(*mass[i]+7));
      |                                 ^~~~~~~~~~~~
Language: C++

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

int main(){
	string line[8];

	while(){


		int w = 0, h = 0, t=-1;

		for(int i=0;i<8;++i)
			cin >> line[i];

		int right=0,left=7;

		for(int i=0;i<8;++i){
			bool exist = false;
			for(int j=0;j<8;++j){
				if((line[i])[j] == '1'){
					if(t!=-1)t=i;
					if(j>right)right = j;
					if(j<left)left = j;
					exist = true;
				}
			}
			if(exist)++h;
		}
		w = right - left + 1;

		if( w == 2 && h == 2 )cout<<"A"<<endl;
		else if(w == 1)cout<<"B"<<endl;
		else if(h == 1)cout<<"C"<<endl;


		else if(w==2){
			for(int i=0;i<8;++i){
				if((line[i])[left] == '1'){
					if((line[i])[left+1]=='1')
						cout<<"D"<<endl;
					else
						cout<<"F"<<endl;
					break;
				}
			}
		}

		else if(h==2){
			for(int i=0;i<8;++i){
				if((line[t])[i]=='1'){
					if((line[t+1])[i]=='1')
						cout<<"G"<<endl;
					else
						cout<<"E"<<endl;
				}
			}
		}

	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:15: error: expected primary-expression before ')' token
    8 |         while(){
      |               ^
Language: C++

import java.io.IOException;

public class Main {
	

	public static void main(String[] args) {
		try {
			final int SIZE = 20 + 10 * 8 * ((8 + 4) * 8);// 8桁＋終端　を　8行に＋空行を10回
			byte[] buf = new byte[SIZE];// 入力データをすべて格納する
			int count = 0;// 文字の先頭からの順番
			int limit = System.in.read(buf, 0, SIZE);

			while (count < limit) {
				int box[] = new int[4];
				int i = 0;
				int head = 0;
				int[] x = new int[4];
				while (count < limit) {
					if (buf[count] == '1') {
						box[i] = count;
						x[i] = head;
						i++;
						
					}
					if (buf[count] != '0' && buf[count] != '1')
						head = 0;
					else
						head++;
					count++;
					if(i > 3) break;
				}
				
				if(i != 4 ) break;
				
				if (box[0] == box[1] - 1) {
					// ACEG
					switch (x[2] - x[0]) {
					case -1:
						System.out.println("G");
						break;
					case 0:
						System.out.println("A");
						break;
					case 1:
						System.out.println("E");
						break;
					case 2:
						System.out.println("C");
						break;
					}
				} else {
					// BDF
					switch (x[3] - x[0]) {
					case -1:
						System.out.println("D");
						break;
					case 0:
						System.out.println("B");
						break;
					case 1:
						System.out.println("F");
						break;
					}
				}
			}
		} catch (IOException e) {
			e.printStackTrace();
		}

	}

}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.io.IOException;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:3:1: error: expected unqualified-id before 'public'
    3 | public class Main {
      | ^~~~~~
Language: C++

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

void figure(char a[8][8])
{
  int i,j;
  for(i=0;i<8;i++)
    for(j=0;j<8;j++)
      if(a[i][j]=='1'){
	if(a[i][j+1]=='1'){
	  if(a[i+1][j]=='1' && a[i+1][j+1]=='1')
	    printf("A\n");
	  else if(a[i][j+2]=='1' && a[i][j+3]=='1')
	    printf("C\n");	
	  else if(a[i+1][j+1]=='1' && a[i+1][j+2]=='1')
	    printf("E\n");
	  else if(a[i+1][j]=='1' && a[i+1][j-1]=='1')
	    printf("G\n");
	}
	else if(a[i+1][j]=='1'){
	  if(a[i+2][j]=='1' && a[i+3][j]=='1')
	    printf("B\n");
	  else if(a[i+1][j-1]=='1' && a[i+2][j-1]=='1')
	    printf("D\n");
	  else if(a[i+1][j+1]=='1' && a[i+2][j+1]=='1')
	    printf("F\n");
	}
	goto OUT;
      }
 OUT:;
}

int main(void)
{
  char a[8][8];
  char *buf;
  int i,j,flag;
  while(1){
    for(i=0;i<8;i++){
      buf=malloc(sizeof(char)*9);
      if(fgets(buf,sizeof(char)*9,stdin)==NULL){
	goto OUT;
      }
      if(flag==1)break;
      // buf[8]='\0';
      for(j=0;j<8;j++)
	a[i][j]=buf[j];
      free(buf);
      //rewind(stdin);//これがないと変になる
    }
    figure(a);
   
  }
 OUT:
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:41:17: error: invalid conversion from 'void*' to 'char*' [-fpermissive]
   41 |       buf=malloc(sizeof(char)*9);
      |           ~~~~~~^~~~~~~~~~~~~~~~
      |                 |
      |                 void*