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

#include <iostream>
#include <queue>
#include <string>
#include <map>
#include <stdio.h>

using namespace std;

int dd[] = {1, -1, 4, -4};

int dfs(string cards){
    //その時のカードの状態をqueueに突っ込む
    map<string, int> done;
    queue<string> que;
    
    if(cards == "01234567")
        return 0;
    
    que.push(cards);
    while(!que.empty()){
        string q = que.front(); que.pop();
        int x0 = q.find("0");
        for(int i=0; i<4; i++){
            string t = q;
            int nx = x0+dd[i];
            if(nx<0 || 7<nx || (x0==3&&i==0) || (x0==4&&i==1))
                continue;
            t[x0] = t[nx];
            t[nx] = '0';
            if(done.count(t))
                continue;
            done[t] = done[q] + 1;
            if(t == "01234567")
                return done[t];
            que.push(t);
        }
    }
    return 0;
}

int main(){
    string t;
    while(getline(cin,t)){
		t.erase(remove(t.begin(),t.end(),' '),t.end());
        cout << dfs(t) << endl;
	}
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:44:39: error: cannot convert 'std::__cxx11::basic_string<char>::iterator' to 'const char*'
   44 |                 t.erase(remove(t.begin(),t.end(),' '),t.end());
      |                                ~~~~~~~^~
      |                                       |
      |                                       std::__cxx11::basic_string<char>::iterator
In file included from /usr/include/c++/14/cstdio:42,
                 from /usr/include/c++/14/ext/string_conversions.h:45,
                 from /usr/include/c++/14/bits/basic_string.h:4154,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/stdio.h:158:32: note:   initializing argument 1 of 'int remove(const char*)'
  158 | extern int remove (const char *__filename) __THROW;
      |                    ~~~~~~~~~~~~^~~~~~~~~~
Language: C++

#include <iostream>
#include <queue>
#include <vector>
#include <set>

using namespace std;

#define loop(i,a,b) for(int i=(a); i<(int)(b); i++)
#define rep(i,b) loop(i,0,b)

typedef vector<int> vi;

struct state {
    int v[8];
    int step, x, y;
};

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

inline bool in(int x, int y){
    return 0 <= x && x < 4 && 0 <= y && y < 2;
}

int hashh(const int v[8]){
    int res = 0;
    rep(i, 8){
        res <<= 3;
        res |= v[i];
    }
    return res;
}

void disp(state s){
    rep(i, 2){
        rep(j, 4){
            cout << s.v[i * 2 + j];
        }
        cout << endl;
    }
    cout << endl;
}

bool dp[1 << 24] = {};

int main(){
    int fin = 0;
    rep(i, 8){
        fin <<= 3; fin |= i;
    }

    while (1){
        memset(dp, 0, sizeof(dp));
        state s;
        s.step = 0;
        rep(i, 8){
            if (!(cin >> s.v[i])) return 0;
            if (s.v[i] == 0){
                s.x = i % 4;
                s.y = i / 4;
            }
        }

        queue<state> q;
        q.push(s);
        int ans = -1;
        while (q.size()){
            state s = q.front();
            q.pop();

            int h = hashh(s.v);
            if (dp[h]) continue;
            dp[h] = true;

            // disp(s);

            if (h == fin){
                ans = s.step;
                break;
            }

            rep(i, 4){
                int xx = s.x + dx[i];
                int yy = s.y + dy[i];
                if (in(xx, yy)){
                    state next = s;
                    next.x = xx;
                    next.y = yy;
                    int n_space = xx + 4 * yy;
                    swap(next.v[n_space], next.v[s.x + s.y * 4]);
                    next.step++;
                    q.push(next);
                }
            }
        }

        cout << ans << endl;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:53:9: error: 'memset' was not declared in this scope
   53 |         memset(dp, 0, sizeof(dp));
      |         ^~~~~~
a.cc:5:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    4 | #include <set>
  +++ |+#include <cstring>
    5 |
Language: C++

#include <cstdio>
#include <vector>
#include <queue>
#include <map>

using namespace std;

#define MAX_HIT ((0<<0)|(1<<3)|(2<<6)|(3<<9)|(4<<12)|(5<<15)|(6<<18)|(7<<21))

bool hit[MAX_HIT+1];


int swap_pos(int value, int i, int j)
{
	int vi, vj;
	i*=3; j*=3;
	vi = (value>>i) & 7;
	vj = (value>>j) & 7;

	value = (value & ~(7<<i)) | (vj<<i);
	value = (value & ~(7<<j)) | (vi<<j);
	return value;

}


int main()
{
	//freopen("in.txt", "r", stdin);

	int target, src;
	int i, j;

	target=0;
	for (i=0; i<=7; i++) {
		target = (target<<3)|i;
	}

	//printf("MAX_HIT=0x%x\n", MAX_HIT);

	while (scanf("%d", &src)==1) {
		for (i=1; i<=7; i++) {
			int tmp;
			scanf("%d", &tmp);
			src = (src<<3) | tmp;
		}

		//printf("target=%d, src=%d\n", target, src);

		memset(hit, 0, sizeof(hit));

		hit[src] = true;

		queue<int> q1, q2, *q, *nq, *qtmp;
		q = &q1; nq = &q2;
		q1.push(src);
		int step = 0;

		while (!hit[target]) {
			while (!nq->empty()) nq->pop();
			step++;
			while (!q->empty()) {
				int value = q->front(); q->pop();
				int next_value;

				for (i=0; i<7; i++) {
					next_value = swap_pos(value, i, i+1);
					if (hit[next_value]==false) {
						hit[next_value] = true;
						nq->push(next_value);
					}
				}
				if (hit[target]) break;
			}

			qtmp = q; q = nq; nq = qtmp;

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

	}

	return 0;
}

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

#include <iostream>
#include <queue>
#include <map>
#include <string>
#include <algorithm>

using namespace std;

typedef pair<string, int> P;

const int INF = 100000000;

//霎灘?
string a;

//遘サ蜉ィ譁ケ蜷?int dir[4] = {-1, 1, -4, 4};

map<string, int> dp;                        //菫晏ュ倅サ市tring蜿伜芦"01234567"逧?nt

//隶。邂嶺サ?01234567"霓ャ謐「蛻ー蜈カ莉門コ丞?謇?怙逧?怙蟆乗ュ・謨ー
void bfs(){
    //蛻晏ァ句喧
    queue<P> que;
    que.push(P("01234567", 0));
    dp["01234567"] = 0;
    //螳ス蠎ヲ莨伜?謳懃エ「
    while(!que.empty()){
        P p = que.front();
        que.pop();
        string s = p.first;
        int cur = p.second;
        for(int i = 0; i < 4; i ++){
            //譫??荳倶ク?ャ。莠、謐「
            int next = cur + dir[i];
            string str = s;
            swap(str[cur], str[next]);
            map<string, int>::iterator it = dp.find(str);
            //蛻、譁ュ譏ッ蜷ヲ蜿ッ遘サ蜉ィ莉・蜿頑弍蜷ヲ隶ソ髣ョ霑?            if(0 <= next && next < 8 
                && !(cur == 3 && next == 4) && !(cur == 4 && next == 3) 
                && it == dp.end()){

                que.push(P(str, next));
                dp[str] = dp[s] + 1;
            }
        }
    }
}

void solve(){
    //蛻?勁遨コ譬シ
    a.erase(remove(a.begin(), a.end(), ' '), a.end());
    cout<<dp[a]<<endl;
}

int main(int argc, char const *argv[]){
    //蜈磯?蜷第桷騾?園譛画ュ蜀オ?悟錘逶エ謗・隸サ蜿冶セ灘?逕ィ萓狗噪扈捺棡
    bfs();
    while(getline(cin, a)){
        solve();
    }
    return 0;
}

Compiler output:
a.cc: In function 'void bfs()':
a.cc:34:30: error: 'dir' was not declared in this scope; did you mean 'div'?
   34 |             int next = cur + dir[i];
      |                              ^~~
      |                              div
a.cc:39:20: error: expected identifier before '!' token
   39 |                 && !(cur == 3 && next == 4) && !(cur == 4 && next == 3)
      |                    ^
Language: C++

#include <iostream>
#include <vector>
#include <string>
#include <queue>
#include <map>
#define INF 10000000
using namespace std;
typedef pair<int,int> P;


void swap(char *a,char *b){
  char temp = *a;
  *a = *b;
  *b = temp;
}

int main(){
  int dx[] = {+1,-1,+4,-4};

  string start = "01234567";

  queue<string> que;
  map<string,int> d;
  que.push(start);
  d[start] = 0;

  while(que.size()){
    string q = que.front(); que.pop();
    int x = q.find("0");
    for(int i=0;i<4;i++){
      int next = x + dx[i];
      if( next>=0 && next<=7 && !(x==3&&next==4) && !(x==4&&next==3) ){
        string nextq = q;
        swap(&nextq[x],&nextq[next]);
        if(d.find(nextq)==d.end()){
          que.push(nextq);
          d[nextq] = d[q] + 1;
        }
      }
    }
  }

  while(1){
    string input = "";
    char temp;
    for(int i=0;i<8;i++){
      if(cin >> temp){
        input.push_back(temp);
      }else{
        return 0;
      }
    }
    cout << d[input] << endl;
  }
}
}

Compiler output:
a.cc:56:1: error: expected declaration before '}' token
   56 | }
      | ^
Language: C++

#include <iostream>
#include <string>
#include <vector>
#include <algorithm>

#define REP(i,k,n) for(int i=k;i<n;i++)
#define rep(i,n) for(int i=0;i<n;i++)
#define pb push_back
#define mp make_pair

using namespace std;

int dx[12] = {-1, 0, 1, 2, 2, 2, 1, 0,-1,-2,-2,-2};
int dy[12] = { 2, 2, 2, 1, 0,-1,-2,-2,-2,-1, 0,-1};
vector<pair<int,int> > v;
bool ans = false;

void dfs(int n,int i,int y,int x)
{
	if(i == n)
	{
		ans = true;
		return;
	}
	else
	{
		bool flag = true;
		int f[10][10];
		memset(f,0,sizeof(f));

		REP(k,-1,2)
		{
			REP(l,-1,2)
			{
				int py = v[i].first + k;
				int px = v[i].second + l;

				if(0 <= py && py < 10 && 0 <= px && px < 10)
				{
					f[py][px] = 1;
				}
			}
		}

		rep(j,12)
		{
			int nx = x + dx[j];
			int ny = y + dy[j];

			if(0 <= ny && ny < 10 && 0<= nx && nx < 10)
			{
				if(f[ny][nx] == 1)
				{
					flag = true;
					dfs(n,i+1,ny,nx);
				}
			}
			
		}
		if(flag) return;
	}
}

int main()
{
	
	while(true)
	{
		int x,y;
		cin >> x >> y;
		if(x == 0 && y == 0) break;

		v.clear();
		ans = false;
		
		int n,sp_x,sp_y;
		cin >> n;

		rep(i,n)
		{
			cin >> sp_x >> sp_y;
			v.pb(mp(sp_y,sp_x));
		}

		dfs(n,0,y,x);

		if(ans) cout << "OK" << endl;
		else cout << "NA" << endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'void dfs(int, int, int, int)':
a.cc:29:17: error: 'memset' was not declared in this scope
   29 |                 memset(f,0,sizeof(f));
      |                 ^~~~~~
a.cc:5:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    4 | #include <algorithm>
  +++ |+#include <cstring>
    5 |
Language: C++

#include<bits/stdc++.h>
#define mk make_pair
using namespace std;
int dx[]={2,2,2,1,1,0,0,-1,-1,-2,-2,-2};
int dy[]={1,0,-1,2,-2,2,-2,2,-2,1,0,-1};
int n,px,py,x,y;
int main(){
  while(cin>>px>>py,px+py){
    cin>>n;
    vector<pair<int,int> >v;
    v.push_back(mk(px,py));
    if(n==0)cout<<"NA"<<endl;
    else{
    for(int o=0;o<n;o++){
      set<pair<int,int> >se;
      vector<pair<int,int> >t;
      cin>>x>>y;
      for(int i=0;i<v.size();i++){
        int sx=v[i].first,sy=v[i].second;
        for(int j=0;j<12;j++){
          int gx=dx[j]+sx,gy=dy[j]+sy;
          if(abs(gx-x)<=1&&abs(gy-y)<=1&&gy>=0&&gx>=0&&gy<10&&gx<10){
            if(se.count(mk(gx,gy)))continue;
            t.push_back(mk(gx,gy));
            se.insert(mk(gx,gy));
          }
        }
      }v=t;
    }
    if(dfs(px,py,0))cout<<"OK"<<endl;
    else cout<<"NA"<<endl;}
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:30:8: error: 'dfs' was not declared in this scope; did you mean 'ffs'?
   30 |     if(dfs(px,py,0))cout<<"OK"<<endl;
      |        ^~~
      |        ffs
Language: C++

#include <iostream>
#include <vector>
#include <algorithm>
#include <cstdio>
#include <queue>

using namespace std;
typedef pair<int, int> P;
typedef pair<int, P> S;

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

bool check(int x, int y) 
{
    return (x >= 0 && x < 10 && y >= 0 && y < 10);
}

int main()
{
    int sx, sy, n;
    int field[10][10];
    while(cin >> sx >> sy && sx && sy) {
        cin >> n;
        vector<P> v(n);
        memset(field, 0,  10 * 10);
        for(int k = 0; k < n; k++) {
            int x, y;
            cin >> x >> y;
            for(int i = -1; i <= 1; i++) 
                for(int j = -1; j <= 1; j++) 
                    if(check(x + j, y + i)) 
                        field[y + i][x + j] += 1 << k;
                       
            
        }
                       
        queue<S> que;
        que.push(S(0, P(sx, sy)));
        bool ok = false;
        while(!que.empty()) {
            S s = que.front(); que.pop();
            P p = s.second;
            int c = s.first, x = p.first, y = p.second;
            if(c == n - 1) {
                ok = true;
                break;
            }
            for(int i = 0; i < 12; i++) {
                int xx = x + dx[i], yy = y + dy[i];
                if(!check(xx, yy)) continue;
                if(field[yy][xx] & c == c) que.push(S(c + 1, P(xx, yy)));
            }
        }
        cout << ((ok) ? "OK" : "NA") << endl;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:26:9: error: 'memset' was not declared in this scope
   26 |         memset(field, 0,  10 * 10);
      |         ^~~~~~
a.cc:6:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    5 | #include <queue>
  +++ |+#include <cstring>
    6 |
Language: C++

 NA:
    mlst.clear();
    nxt.clear();
    for(i=0;i<10;i++){
      for(j=0;j<10;j++){
	mp[i][j].clear();
      }
    }
      
  }while(1);
  return 0;
}

Compiler output:
a.cc:1:4: error: found ':' in nested-name-specifier, expected '::'
    1 |  NA:
      |    ^
      |    ::
a.cc:1:2: error: 'NA' does not name a type
    1 |  NA:
      |  ^~
a.cc:3:5: error: 'nxt' does not name a type
    3 |     nxt.clear();
      |     ^~~
a.cc:4:5: error: expected unqualified-id before 'for'
    4 |     for(i=0;i<10;i++){
      |     ^~~
a.cc:4:13: error: 'i' does not name a type
    4 |     for(i=0;i<10;i++){
      |             ^
a.cc:4:18: error: 'i' does not name a type
    4 |     for(i=0;i<10;i++){
      |                  ^
a.cc:10:3: error: expected declaration before '}' token
   10 |   }while(1);
      |   ^
a.cc:10:4: error: expected unqualified-id before 'while'
   10 |   }while(1);
      |    ^~~~~
a.cc:11:3: error: expected unqualified-id before 'return'
   11 |   return 0;
      |   ^~~~~~
a.cc:12:1: error: expected declaration before '}' token
   12 | }
      | ^
Language: C++

				return 1;
		}
	}

	return 0;//Ç¤ ª¢Äàâ]
}

int main(){
	int posX, posY;
	while(std::cin >> posX >> posY, posX && posY){
		std::cin >> n;
		for(int i=0;i<n;i++){
			int wposX, wposY;
			std::cin >> wposX >> wposY;
			wpos[i] = P(wposX, wposY);
		}
		
		if(dfs(posX, posY, 0))puts("OK");
		else puts("NA");
	}
}

Compiler output:
a.cc:1:33: error: expected unqualified-id before 'return'
    1 |                                 return 1;
      |                                 ^~~~~~
a.cc:2:17: error: expected declaration before '}' token
    2 |                 }
      |                 ^
a.cc:3:9: error: expected declaration before '}' token
    3 |         }
      |         ^
a.cc:5:9: error: expected unqualified-id before 'return'
    5 |         return 0;//Ç¤ ª¢Äàâ]
      |         ^~~~~~
a.cc:6:1: error: expected declaration before '}' token
    6 | }
      | ^
a.cc: In function 'int main()':
a.cc:10:20: error: 'cin' is not a member of 'std'
   10 |         while(std::cin >> posX >> posY, posX && posY){
      |                    ^~~
a.cc:1:8: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 |                                 return 1;
a.cc:11:22: error: 'cin' is not a member of 'std'
   11 |                 std::cin >> n;
      |                      ^~~
a.cc:11:22: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:11:29: error: 'n' was not declared in this scope
   11 |                 std::cin >> n;
      |                             ^
a.cc:14:30: error: 'cin' is not a member of 'std'
   14 |                         std::cin >> wposX >> wposY;
      |                              ^~~
a.cc:14:30: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:15:25: error: 'wpos' was not declared in this scope; did you mean 'wposY'?
   15 |                         wpos[i] = P(wposX, wposY);
      |                         ^~~~
      |                         wposY
a.cc:15:35: error: 'P' was not declared in this scope
   15 |                         wpos[i] = P(wposX, wposY);
      |                                   ^
a.cc:18:20: error: 'dfs' was not declared in this scope
   18 |                 if(dfs(posX, posY, 0))puts("OK");
      |                    ^~~
a.cc:18:39: error: 'puts' was not declared in this scope
   18 |                 if(dfs(posX, posY, 0))puts("OK");
      |                                       ^~~~
a.cc:19:22: error: 'puts' was not declared in this scope
   19 |                 else puts("NA");
      |                      ^~~~
Language: Java

ublic class Main {
	double[] grade_500 = {35.5, 37.5, 40.0, 43.0, 50.0, 55.0, 70.0};
	double[] grade_1000 = {71.0, 77.0, 83.0, 89.0, 105.0, 116.0, 148.0};
	String[] grade = {"AAA", "AA", "A", "B", "C", "D", "E"};
	public void solve() throws IOException{
		while( stdIn.hasNext() ){
			double x = stdIn.nextDouble();
			double y = stdIn.nextDouble();
			int g1 = 7; int g2 = 7;
			for(int i = 0; i < 7; i++){
				if( x < grade_500[i] ){
					g1 = i;
					break;
				}
			}
			for(int i = 0; i < 7; i++){
				if( y < grade_1000[i] ){
					g2 = i;
					break;
				}
			}
			int index = Math.max(g1, g2);
			if( index == 7 ){
				writer.println("NA");
			} else {
				writer.println(grade[index]);
			}
			writer.flush();			
		}
	//	writer.flush();
	} 
			
	public static void main (String args[]) throws IOException {
		new Main().run();
	}
	Scanner stdIn;
	PrintWriter writer;
	
	public void run() throws IOException{
		stdIn = null;
		try{
			stdIn = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
			writer = new PrintWriter(System.out);
			solve();
			stdIn.close();
			writer.close();
		} catch (Exception e){
			e.printStackTrace();
			System.exit(1);
		}
	}
}

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
ublic class Main {
^
1 error
Language: C

#include<stdioh>
int main(void) {
	double a, b;
	scanf("%f %f",&a,&b);
	if(a <= 35.5)
		if(b <= 71.0)
			printf("AAA\n");
		else
			if(b <= 77.0)
				printf("AA\n");
			else
				if(b <= 83.0)
					printf("A\n");
				else
					if(b <= 89.0)
						printf("B\n");
					else
						if(b <= 105.0);
							printf("C\n");
						else
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
	else
		if(a <= 37.5)
			if(b <= 77.0)
				printf("AA\n");
			else
				if(b <= 83.0)
					printf("A\n");
				else
					if(b <= 89.0)
						printf("B\n");
					else
						if(b <= 105.0);
							printf("C\n");
						else
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
		else
			if(a <= 40.0)
				if(b <= 83.0)
					printf("A\n");
				else
					if(b <= 89.0)
						printf("B\n");
					else
						if(b <= 105.0);
							printf("C\n");
						else
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
			else
				if(a <= 43.0)
					if(b <= 89.0)
						printf("B\n");
					else
						if(b <= 105.0);
							printf("C\n");
						else
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
				else
					if(a <= 50.0)
						if(b <= 105.0);
							printf("C\n");
						else
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
					else
						if(a <= 55.0)
							if(b <= 116.0)
								printf("D\n")
							else
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
						else
							if(a <= 70.0)
								if(b <= 148.0)
									printf("E\n");
								else
									printf("NA\n");
							else
								printf("NA\n");
	return 0;
}

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

#include <stdio.h>

int main()
{
	double t1, t2;
	double t[7][2] = {{35.5, 71.0}, {37.5, 77.0}, {40.0, 83.0}, {43.0, 89.0},
                      {50.0, 105.0}, {55.0, 116.0}, {70.0, 148.0}};
	int i1, k = -1;
	char kyu[8][5] = {"AAA", "AA", "A", "B", "C", "D", "E", "NA"};
					// ??\?????\?????\??¨???????£???????
	scanf("%lf %lf", &t1, &t2);
					// ????¬¢????????????	for (i1 = 0; i1 < 7 && k < 0; i1++) {
		if (t1 < t[i1][0] && t2 < t[i1][1])
			k = i1;
	}

	if (k < 0)
		k = 7;

	printf("%s\n", kyu[k]);

	return 0;
}

Compiler output:
main.c:17:9: error: expected identifier or '(' before 'if'
   17 |         if (k < 0)
      |         ^~
main.c:20:16: error: expected declaration specifiers or '...' before string constant
   20 |         printf("%s\n", kyu[k]);
      |                ^~~~~~
main.c:20:24: error: unknown type name 'kyu'
   20 |         printf("%s\n", kyu[k]);
      |                        ^~~
main.c:22:9: error: expected identifier or '(' before 'return'
   22 |         return 0;
      |         ^~~~~~
main.c:23:1: error: expected identifier or '(' before '}' token
   23 | }
      | ^
Language: C

/*************************************/
/*     ??\?????\?????\?????\??¬???????????±???006???????????????1?????? */
/*          coded by Y.Suganuma      */
/*************************************/
#include <stdio.h>

int main()
{
	double t1, t2;
	double t[7][2] = {{35.5, 71.0}, {37.5, 77.0}, {40.0, 83.0}, {43.0, 89.0},
                      {50.0, 105.0}, {55.0, 116.0}, {70.0, 148.0}};
	int i1, k = -1;
	char kyu[8][5] = {"AAA", "AA", "A", "B", "C", "D", "E", "NA"};
					// ??\?????\?????\??¨???????£???????
	scanf("%lf %lf", &t1, &t2);
					// ????¬¢????????????	for (i1 = 0; i1 < 7 && k < 0; i1++) {
		if (t1 < t[i1][0] && t2 < t[i1][1])
			k = i1;
	}

	if (k < 0)
		k = 7;

	printf("%s\n", kyu[k]);

	return 0;
}

Compiler output:
main.c:21:9: error: expected identifier or '(' before 'if'
   21 |         if (k < 0)
      |         ^~
main.c:24:16: error: expected declaration specifiers or '...' before string constant
   24 |         printf("%s\n", kyu[k]);
      |                ^~~~~~
main.c:24:24: error: unknown type name 'kyu'
   24 |         printf("%s\n", kyu[k]);
      |                        ^~~
main.c:26:9: error: expected identifier or '(' before 'return'
   26 |         return 0;
      |         ^~~~~~
main.c:27:1: error: expected identifier or '(' before '}' token
   27 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
float a,b;
int c;
	while(0<c=scanf("%f %f",&a,&b)){
	if(a>=70.00||b>=148.00)
	{
		printf("NA\n");
	}
	else if(a<35.50&&b<71.00)
	{
		printf("AAA\n");
	}
	else if(a<37.00&&b<77.00)
	{
		printf("AA\n");
	}
	else if(a<40.00&&b<83.00)
	{
		printf("A\n");
	}
	else if(a<43.00&&b<89.00)
	{
		printf("B\n");
	}
	else if(a<50.00&&b<105.00)
	{
		printf("C\n");
	}
	else if(a<55.00&&b<116.00)
	{
		printf("D\n");
	}
	else
	{
		printf("E\n");
	}
}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:18: error: lvalue required as left operand of assignment
    6 |         while(0<c=scanf("%f %f",&a,&b)){
      |                  ^
Language: C

#include<stdio.h>
int main(void)
{
float a,b;
int c;
	while(0<c=scanf("%f %f",&a,&b))
	{
	if(a<35.50&&b<71.00)
	{
		printf("AAA\n");
	}
	else if(a<37.00&&b<77.00)
	{
		printf("AA\n");
	}
	else if(a<40.00&&b<83.00)
	{
		printf("A\n");
	}
	else if(a<43.00&&b<89.00)
	{
		printf("B\n");
	}
	else if(a<50.00&&b<105.00)
	{
		printf("C\n");
	}
	else if(a<55.00&&b<116.00)
	{
		printf("D\n");
	}
	else if(a<70.00&&b<148.00)
	{
		printf("E\n");
	}
	else
	{
		printf("E\n");
	}
}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:18: error: lvalue required as left operand of assignment
    6 |         while(0<c=scanf("%f %f",&a,&b))
      |                  ^
Language: C

include<stdio.h>
int main(){
  double a,b;
  int c,d,e;
  while(scanf("%lf %lf",&a,&b)!=EOF){
    if(a<35.50)c=1;
    else if(a<37.50)c=2;
    else if(a<40.00)c=3;
    else if(a<43.00)c=4;
    else if(a<50.00)c=5;
    else if(a<55.00)c=6;
    else if(a<70.00)c=7;
    else c=0;
    
    if(b<71.00)d=1;
    else if(b<77.00)d=2;
    else if(b<83.00)d=3;
    else if(b<89.00)d=4;
    else if(b<105.00)d=5;
    else if(b<116.00)d=6;
    else if(b<148.00)d=7;
    else d=0;
    
    if(c==0||d==0)printf("NA\n");
    else{
      if(d>c)c=d;

      if(c==1)printf("AAA\n");
      else if(c==2)printf("AA\n");
      else printf("%c\n",c+'A'-3);
    }
  }
  return 0;
}

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

include <stdio.h>

int main(){
    double five=0, ten = 0;
    for(;;){
        scanf("%lf %lf",&five, &ten);
        if(five < 35.5 && ten < 71.0){
            printf("AAA/n");
        }
        else if (five < 37.5 && ten < 77.0){
            printf("AA/n");
        }
        else if (five < 40.0 && ten < 83.0){
            printf("A/n");
        }
        else if (five < 43.0 && ten < 89.0){
            printf("B\n");
        }
        else if (five < 50.0 && ten < 105.0){
            printf("C\n");
        }
        else if (five < 55.0 && ten < 116.0){
            printf("D\n");
        }
        else if (five < 70.0 && ten < 148.0){
            printf("E\n");
        }
        else{
            printf("NA\n");
        }
    }
    return (0);
}

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

#include<stdio.h>
#include<iostream>
using namespace std;
void TR(double x,double y,int K,int H)
{
int t;
double X;
X=x*100;t=(int)X;
if(t<3550)K=0;
else if(t<3550)K=0;
else if(t<3750)K=1;
else if(t<4000)K=2;
else if(t<4300)K=3;
else if(t<5000)K=4;
else if(t<5500)K=5;
else if(t<7000)K=6;
else if(t>=7000)K=7;

X=y*100;t=(int)X;
if(t<3550)K=0;
else if(t<7100)H=0;
else if(t<7700)H=1;
else if(t<8300)H=2;
else if(t<8900)H=3;
else if(t<10500)H=4;
else if(t<11600)H=5;
else if(t<14800)H=6;
else if(t>=14800)H=7;
}


}
int main(){
int K=0,H=0;
double x,y;
while(scanf("%lf %lf",&x,&y)!=EOF)
{K=0,H=0;

TR(x,y,K,H);
if(H<K)H=K;

switch(K){
case 0:
cout<<"AAA"<<endl;break;
case 1:
cout<<"AA"<<endl;break;
case 2:
cout<<"A"<<endl;break;
case 3:
cout<<"B"<<endl;break;
case 4:
cout<<"C"<<endl;break;
case 5:
cout<<"D"<<endl;break;
case 6:
cout<<"E"<<endl;break;
case 7:
cout<<"NA"<<endl;break;

}
}
return 0;
}

Compiler output:
a.cc:32:1: error: expected declaration before '}' token
   32 | }
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	int a,b;
	scanf("%d %d",&a,&b);
	if(a<=35.5 && b<=71){
		printf("AAA\n");
	}
	else if(a<37.5 && b<77){
		printf("AA\n");
	}
	else if(a<40 && b<83){
		printf("A\n");
	}
	else if(a<43 && b<89){
		printf("B\n");
	}
	else if(a<50 && b<105){
		printf("c\n");
	}
	else if(a<55 && b<116){
		printf("D\n");
	}
	else if(a<60 && b<148){
		printf("E\n");
	}
	else{
		printf("NA\n");
	}
	return 0;
}

	

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	int a,b;
	while(scanf("%d %d",&a,&b)!=EOF){
		if(a<=35.5 && b<=71){
			printf("AAA\n");
		}
		else if(a<37.5 && b<77){
			printf("AA\n");
		}
		else if(a<40 && b<83){
			printf("A\n");
		}
		else if(a<43 && b<89){
			printf("B\n");
		}
		else if(a<50 && b<105){
			printf("c\n");
		}
		else if(a<55 && b<116){
			printf("D\n");
		}
		else if(a<60 && b<148){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
	}
	return 0;
}

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	int a,b;
	while(scanf("%d %d",&a,&b)!=EOF){
		if(a<=35.5 && b<=71){
			printf("AAA\n");
		}
		else if(a<37.5 && b<77){
			printf("AA\n");
		}
		else if(a<40 && b<83){
			printf("A\n");
		}
		else if(a<43 && b<89){
			printf("B\n");
		}
		else if(a<50 && b<105){
			printf("c\n");
		}
		else if(a<55 && b<116){
			printf("D\n");
		}
		else if(a<60 && b<148){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
		scanf("%d %d",&a,&b);
	}
	return 0;
}

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	double a,b;
	while(scanf("%lf %lf",&a,&b)!=EOF){
		if(a<=35.5 && b<=71){
			printf("AAA\n");
		}
		else if(a<37.5 && b<77){
			printf("AA\n");
		}
		else if(a<40 && b<83){
			printf("A\n");
		}
		else if(a<43 && b<89){
			printf("B\n");
		}
		else if(a<50 && b<105){
			printf("c\n");
		}
		else if(a<55 && b<116){
			printf("D\n");
		}
		else if(a<60 && b<148){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
	//	scanf("%d %d",&a,&b);
	}
	return 0;
}

	

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	double a,b;
	while(scanf("%lf %lf",&a,&b)!=EOF){
		if(a<35.5 && b<71){
			printf("AAA\n");
		}
		else if(a<37.5 && b<77){
			printf("AA\n");
		}
		else if(a<40 && b<83){
			printf("A\n");
		}
		else if(a<43 && b<89){
			printf("B\n");
		}
		else if(a<50 && b<105){
			printf("c\n");
		}
		else if(a<55 && b<116){
			printf("D\n");
		}
		else if(a<60 && b<148){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
	//	scanf("%d %d",&a,&b);
	}
	return 0;
}

	

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

#include<stdio.h>
int main(main)
{
	double a,b;
	while(scanf("%lf %lf",&a,&b)!=EOF){
		if(a<35.5 && b<71){
			printf("AAA\n");
		}
		else if(a<37.5 && b<77){
			printf("AA\n");
		}
		else if(a<40 && b<83){
			printf("A\n");
		}
		else if(a<43 && b<89){
			printf("B\n");
		}
		else if(a<50 && b<105){
			printf("C\n");
		}
		else if(a<55 && b<116){
			printf("D\n");
		}
		else if(a<60 && b<148){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
	//	scanf("%d %d",&a,&b);
	}
	return 0;
}

Compiler output:
a.cc:2:5: error: cannot declare '::main' to be a global variable
    2 | int main(main)
      |     ^~~~
a.cc:3:1: error: expected ',' or ';' before '{' token
    3 | {
      | ^
Language: C++

/*************************************/
/*     ??\?????\?????\?????\??¬???????????±???006???????????????1?????? */
/*          coded by Y.Suganuma      */
/*************************************/
#include <stdio.h>

int main()
{
	double t1, t2;
	double t[7][2] = {{35.5, 71.0}, {37.5, 77.0}, {40.0, 83.0}, {43.0, 89.0},
                      {50.0, 105.0}, {55.0, 116.0}, {70.0, 148.0}};
	int i1, k = -1;
	char kyu[8][5] = {"AAA", "AA", "A", "B", "C", "D", "E", "NA"};
					// ??\?????\?????\??¨???????£???????
	scanf("%lf %lf", &t1, &t2);
					// ????¬¢????????????	for (i1 = 0; i1 < 7 && k < 0; i1++) {
		if (t1 < t[i1][0] && t2 < t[i1][1])
			k = i1;
	}

	if (k < 0)
		k = 7;

	printf("%s\n", kyu[k]);

	return 0;
}

Compiler output:
a.cc:21:9: error: expected unqualified-id before 'if'
   21 |         if (k < 0)
      |         ^~
a.cc:24:15: error: expected constructor, destructor, or type conversion before '(' token
   24 |         printf("%s\n", kyu[k]);
      |               ^
a.cc:26:9: error: expected unqualified-id before 'return'
   26 |         return 0;
      |         ^~~~~~
a.cc:27:1: error: expected declaration before '}' token
   27 | }
      | ^
Language: C++

#include <stdio.h>

int main()
{
	double t1, t2;
	double t[7][2] = {{35.5, 71.0}, {37.5, 77.0}, {40.0, 83.0}, {43.0, 89.0},
                      {50.0, 105.0}, {55.0, 116.0}, {70.0, 148.0}};
	int i1, k = -1;
	char kyu[8][5] = {"AAA", "AA", "A", "B", "C", "D", "E", "NA"};
					// ??\?????\?????\??¨???????£???????
	scanf("%lf %lf", &t1, &t2);
					// ????¬¢????????????	for (i1 = 0; i1 < 7 && k < 0; i1++) {
		if (t1 < t[i1][0] && t2 < t[i1][1])
			k = i1;
	}

	if (k < 0)
		k = 7;

	printf("%s\n", kyu[k]);

	return 0;
}

Compiler output:
a.cc:17:9: error: expected unqualified-id before 'if'
   17 |         if (k < 0)
      |         ^~
a.cc:20:15: error: expected constructor, destructor, or type conversion before '(' token
   20 |         printf("%s\n", kyu[k]);
      |               ^
a.cc:22:9: error: expected unqualified-id before 'return'
   22 |         return 0;
      |         ^~~~~~
a.cc:23:1: error: expected declaration before '}' token
   23 | }
      | ^
Language: C++

#include <iostream>
using namespace std;
char c[8][8];
int main(){
while(cin>>a>>b){
for(int i=0;i<64;i++)cin>>c[i/8][i%8];
cout<<90<<endl;
for(int i=0;i<8;i++){
for(int j=0;j<8;j++){
cout<<c[7-j][i];
}
cout<<endl;
}
cout<<180<<endl;
for(int i=0;i<8;i++){
for(int j=0;j<8;j++){
cout<<c[7-i][7-j];
}
cout<<endl;
}
cout<<270<<endl;
for(int i=0;i<8;i++){
for(int j=0;j<8;j++){
cout<<c[j][7-i];
}
cout<<endl;
}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:12: error: 'a' was not declared in this scope
    5 | while(cin>>a>>b){
      |            ^
a.cc:5:15: error: 'b' was not declared in this scope
    5 | while(cin>>a>>b){
      |               ^
a.cc:28:2: error: expected '}' at end of input
   28 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

#include<stdio.h>
int main(void)
{
	float t,t1;
	while(!(scanf("%f %f",&t,&t1));
	if(t<35.50 && t1<71.00){
		printf("AAA\n");
	}
	else if(t<37.50 && t1<77.00){
		printf("AA\n");
	}
	else if(t<40.00 && t1<83.00){
		printf("A\n");
	}
	else if(t<43.00 && t1<89.00){
		printf("B\n");
	}
	else if(t<50.00 && t1<95.00){
		printf("C\n");
	}
	else if(t<55.00 && t1<116.00){
		printf("D\n");
	}
	else if(t<70.00 && t1<148.00){
		printf("E\n");
	}
	else{
		printf("NA\n");
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:39: error: expected ')' before ';' token
    5 |         while(!(scanf("%f %f",&t,&t1));
      |              ~                        ^
      |                                       )
Language: C++

#include<stdio.h>
int main(void)
{
	float t,t1;
	while(!(scanf("%f %f",&t,&t1)){
		if(t<35.50 && t1<71.00){
			printf("AAA\n");
		}
		else if(t<37.50 && t1<77.00){
			printf("AA\n");
		}
		else if(t<40.00 && t1<83.00){
			printf("A\n");
		}
		else if(t<43.00 && t1<89.00){
			printf("B\n");
		}
		else if(t<50.00 && t1<95.00){
			printf("C\n");
		}
		else if(t<55.00 && t1<116.00){
			printf("D\n");
		}
		else if(t<70.00 && t1<148.00){
			printf("E\n");
		}
		else{
			printf("NA\n");
		}
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:39: error: expected ')' before '{' token
    5 |         while(!(scanf("%f %f",&t,&t1)){
      |              ~                        ^
      |                                       )
Language: C++

#include<stdio.h>
int main(void)
{
	float a,b;
	
	scanf("%f %f",&a,&b);
	if(a<35.5 && b<71.0){
		printf("AAA\n");
	}
	else if(a<37.5 && b<77.0){
		printf("AA\n");
	}
	else if(a<40.0 && b<83.0){
		printf("A\n");
	}
	else if(a<43.0 && b<89.0){
		printf("B\n");
	}
	else if(a<50.0 && b<105.0){
		printf("C\n");
	}
	else if(a<55.0 && b<116.0){
		printf("D\n");
	}
	else if(a<70.0 && b<148.0){
		printf("E\n");
	}
	else{
		printf("NA\n");
	}
	return 0;
}
#include<stdio.h>
int main(void)
{
	float a,b;
	
	scanf("%f %f",&a,&b);
	if(a<35.5 && b<71.0){
		printf("AAA\n");
	}
	else if(a<37.5 && b<77.0){
		printf("AA\n");
	}
	else if(a<40.0 && b<83.0){
		printf("A\n");
	}
	else if(a<43.0 && b<89.0){
		printf("B\n");
	}
	else if(a<50.0 && b<105.0){
		printf("C\n");
	}
	else if(a<55.0 && b<116.0){
		printf("D\n");
	}
	else if(a<70.0 && b<148.0){
		printf("E\n");
	}
	else{
		printf("NA\n");
	}
	return 0;
}

Compiler output:
a.cc:34:5: error: redefinition of 'int main()'
   34 | int main(void)
      |     ^~~~
a.cc:2:5: note: 'int main()' previously defined here
    2 | int main(void)
      |     ^~~~
Language: C++

#include<stdio.h>
int main(void)
{
	float a,b;
	while(scanf("%d %b",&a,&b)!=EOF{
	if(a<35.5 && b<71.0){
			printf("AAA\n");
			}
	else if(a<37.5 && b<77.0){
			printf("AA\n");
			}
	else if(a<40.0 && b<83.0){
			printf("A\n");
			}
	else if(a<43.0 && b<89.0){
			printf("B\n");
			}
	else if(a<50.0 && b<105.0){
			printf("C\n");
			}
	else if(a<55.0 && b<116.0){
			printf("D\n");
			}
	else if(a<110.0 && b<148.0){
			printf("E\n");
			}
	else{
			printf("NA\n");
			}
			}
		return 0;
}

		

Compiler output:
a.cc: In function 'int main()':
a.cc:5:40: error: expected ')' before '{' token
    5 |         while(scanf("%d %b",&a,&b)!=EOF{
      |              ~                         ^
Language: C++

int main(void)
{
	float a,b;
	while(scanf("%f %f",&a,&b)!=EOF){
	if(a<35.5 && b<71.0){
			printf("AAA\n");
			}
	else if(a<37.5 && b<77.0){
			printf("AA\n");
			}
	else if(a<40.0 && b<83.0){
			printf("A\n");
			}
	else if(a<43.0 && b<89.0){
			printf("B\n");
			}
	else if(a<50.0 && b<105.0){
			printf("c\n");
			}
	else if(a<55.0 && b<116.0){
			printf("D\n");
			}
	else if(a<70.0 && b<148.0){
			printf("E\n");
			}
		else{
			printf("NA\n");
			}
		}
	return 0;
	}
	

Compiler output:
a.cc: In function 'int main()':
a.cc:4:15: error: 'scanf' was not declared in this scope
    4 |         while(scanf("%f %f",&a,&b)!=EOF){
      |               ^~~~~
a.cc:4:37: error: 'EOF' was not declared in this scope
    4 |         while(scanf("%f %f",&a,&b)!=EOF){
      |                                     ^~~
a.cc:1:1: note: 'EOF' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main(void)
a.cc:6:25: error: 'printf' was not declared in this scope
    6 |                         printf("AAA\n");
      |                         ^~~~~~
a.cc:6:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:9:25: error: 'printf' was not declared in this scope
    9 |                         printf("AA\n");
      |                         ^~~~~~
a.cc:9:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:12:25: error: 'printf' was not declared in this scope
   12 |                         printf("A\n");
      |                         ^~~~~~
a.cc:12:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:15:25: error: 'printf' was not declared in this scope
   15 |                         printf("B\n");
      |                         ^~~~~~
a.cc:15:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:18:25: error: 'printf' was not declared in this scope
   18 |                         printf("c\n");
      |                         ^~~~~~
a.cc:18:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:21:25: error: 'printf' was not declared in this scope
   21 |                         printf("D\n");
      |                         ^~~~~~
a.cc:21:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:24:25: error: 'printf' was not declared in this scope
   24 |                         printf("E\n");
      |                         ^~~~~~
a.cc:24:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
a.cc:27:25: error: 'printf' was not declared in this scope
   27 |                         printf("NA\n");
      |                         ^~~~~~
a.cc:27:25: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

#include<iostream>
#include<string>
#include<algorithm>
#include<map>
#include<vector>
#include<cmath>
#include<cstdio>
#define loop(i,a,b) for(i=a;i<b;i++) 
#define rep(i,a) loop(i,0,a)
#define pb(in,tmp) in.push_back(tmp)
#define all(in) in.begin(),in.end()
const double PI=acos(-1);
using namespace std;
int main(){
  double a,b;
  double h[2][8]={
    {70,55,50,43,40,37,35,-1},
    {148,116,105,89,83,77,71,-1}
  };
  string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
  while(cin>>a>>b){
    int i;
    rep(i,8)if(a>=h[0][i]||b>=h[1][i])break;
      cout<<s[i]<<endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:20:21: error: conversion from 'char' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   20 |   string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
      |                     ^~~
a.cc:20:25: error: conversion from 'char' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   20 |   string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
      |                         ^~~
a.cc:20:29: error: conversion from 'char' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   20 |   string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
      |                             ^~~
a.cc:20:33: error: conversion from 'char' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   20 |   string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
      |                                 ^~~
a.cc:20:37: error: conversion from 'char' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   20 |   string s[8]={"NA",'E','D','C','B','A',"AA","AAA"};
      |                                     ^~~
Language: Java

import java.util.*;class Main{public static void main(String[]args){Scanner sc = new Scanner(System.in);int c=0;for(;;){  int???s=sc.nextInt();if(s==0)break;if(c!=0)System.out.println();String tn[] =new String[s];int tp[]=new int[s];  int tpc[]=new int[s];for(int i=0;i<s;i++){ tn[i]=sc.next();tp[i]=(sc.nextInt()*3+sc.nextInt()*0+sc.nextInt());tpc[i]=tp[i];}Arrays.sort(tpc);for(int i=tpc[s-1];i>-1;i--){ for(int j=0;j<s;j++) if(i==tp[j])System.out.println(tn[j]+","+tp[j]);}c++;}}}

Compiler output:
Main.java:1: error: not a statement
import java.util.*;class Main{public static void main(String[]args){Scanner sc = new Scanner(System.in);int c=0;for(;;){  int???s=sc.nextInt();if(s==0)break;if(c!=0)System.out.println();String tn[] =new String[s];int tp[]=new int[s];  int tpc[]=new int[s];for(int i=0;i<s;i++){ tn[i]=sc.next();tp[i]=(sc.nextInt()*3+sc.nextInt()*0+sc.nextInt());tpc[i]=tp[i];}Arrays.sort(tpc);for(int i=tpc[s-1];i>-1;i--){ for(int j=0;j<s;j++) if(i==tp[j])System.out.println(tn[j]+","+tp[j]);}c++;}}}
                                                                                                                          ^
Main.java:1: error: ';' expected
import java.util.*;class Main{public static void main(String[]args){Scanner sc = new Scanner(System.in);int c=0;for(;;){  int???s=sc.nextInt();if(s==0)break;if(c!=0)System.out.println();String tn[] =new String[s];int tp[]=new int[s];  int tpc[]=new int[s];for(int i=0;i<s;i++){ tn[i]=sc.next();tp[i]=(sc.nextInt()*3+sc.nextInt()*0+sc.nextInt());tpc[i]=tp[i];}Arrays.sort(tpc);for(int i=tpc[s-1];i>-1;i--){ for(int j=0;j<s;j++) if(i==tp[j])System.out.println(tn[j]+","+tp[j]);}c++;}}}
                                                                                                                             ^
2 errors
Language: Java

#include<stdio.h>
#include<stdlib.h>
typedef struct team{
	int p;
	char n[23];
}TEAM;
int comp(const void *p,const void *q){
	TEAM *a=(TEAM *)p,*b=(TEAM *)q;
	return b->p - a->p;
}
TEAM x[12];
int main(){
	int n,p,q,r,i,f=1;
	while(scanf("%d",&n)!=EOF){
		if(n==0)break;
		if(f==1)f==0;
		else printf("\n");
		for(i=0;i<n;i++){
			scanf("%s%d%d%d",x[i].n,&p,&q,&r);
			x[i].p=p*3+r;
		}
		qsort(x,n,sizeof(TEAM),comp);
		for(i=0;i<n;i++)printf("%s,%d\n",x[i].n,x[i],p);
	}
	return 0;
}

Compiler output:
Main.java:1: error: illegal character: '#'
#include<stdio.h>
^
Main.java:1: error: class, interface, enum, or record expected
#include<stdio.h>
        ^
Main.java:2: error: illegal character: '#'
#include<stdlib.h>
^
Main.java:5: error: class, interface, enum, or record expected
	char n[23];
	^
Main.java:6: error: class, interface, enum, or record expected
}TEAM;
^
Main.java:7: error: unnamed classes are a preview feature and are disabled by default.
int comp(const void *p,const void *q){
^
  (use --enable-preview to enable unnamed classes)
Main.java:7: error: illegal start of type
int comp(const void *p,const void *q){
         ^
Main.java:7: error: class, interface, enum, or record expected
int comp(const void *p,const void *q){
               ^
Main.java:9: error: class, interface, enum, or record expected
	return b->p - a->p;
	^
Main.java:10: error: class, interface, enum, or record expected
}
^
Main.java:16: error: not a statement
		if(f==1)f==0;
		         ^
Main.java:14: error: illegal start of expression
	while(scanf("%d",&n)!=EOF){
	                 ^
Main.java:19: error: illegal start of expression
			scanf("%s%d%d%d",x[i].n,&p,&q,&r);
			                        ^
Main.java:19: error: illegal start of expression
			scanf("%s%d%d%d",x[i].n,&p,&q,&r);
			                           ^
Main.java:19: error: illegal start of expression
			scanf("%s%d%d%d",x[i].n,&p,&q,&r);
			                              ^
15 errors
Language: C

#include<stdio.h>
struct TeamScore {
	char team_name[21];
	int win_n;
	int lose_n;
	int draw_n;
	int points;
};

int main(void) {
	int n;
	int i,j,k=0;
	while (1) {
		struct TeamScore data[10], *p, temp;
		p = data;
		scanf("%d",&n);
		if (n == 0)break;
		if (k++)putchar('\n');
		for (i = 0; i < n; i++) {
			scanf("%s %d %d %d", &data[i].team_name??? &data[i].win_n, 
				&data[i].lose_n, &data[i].draw_n);
			data[i].points = data[i].win_n * 3 + data[i].draw_n;
		}
		for (i = 0; i < n; i++) {
			for (j = i; j < n; j++) {
				if ((p + i)->points < (p + j)->points) {
					temp = *(p + i);
					*(p + i) = *(p + j);
					*(p + j) = temp;
				}
			}
		}
		for (i = 0; i < n; i++)
			printf("%s,%d\n", (p + i)->team_name, (p + i)->points);
	}
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:20:65: error: expected expression before '?' token
   20 |                         scanf("%s %d %d %d", &data[i].team_name??? &data[i].win_n,
      |                                                                 ^
Language: C

#include<stdio.h>
struct TeamScore {
	char team_name[21];
	int win_n;
	int lose_n;
	int draw_n;
	int points;
};

int main(void) {
	int n;
	int i,j,k=0;
	while (1) {
		struct TeamScore data[10], *p, temp;
		p = data;
		scanf_s("%d",&n);
		if (n == 0)break;
		if (k>0)putchar('\n');
		for (i = 0; i < n; i++) {
			scanf("%s %d %d %d", data[i].team_name, &data[i].win_n, 
				&data[i].lose_n, &data[i].draw_n);
			data[i].points = data[i].win_n * 3 + data[i].draw_n;
		}

		for (i = 0; i < n; i++) {
			for (j = i; j < n; j++) {
				if ((p + i)->points < (p + j)->points) {
					temp = *(p + i);
					*(p + i) = *(p + j);
					*(p + j) = temp;
				}
			}
		}
		for (i = 0; i < n; i++)
			printf("%s,%d\n", (p + i)->team_name, (p + i)->points);
		k = 1;
	}
	return 0;
}

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