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

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

int main()
{
	int n, y;
	bool ok = false;
	stringstream ss;
	string s;

	cin >> n >> y;

	for (int i = y/10000; i >= 0; --i)
	{
		for (int j = 0; j <= n-i; ++j)
		{
			if (10000*i + 5000*j + 1000*(n-i-j) == y)
			{
				ok = true;
				ss << i << " " << j << " " << n-i-j;
				s = ss.str();
				break;
		}
		if (ok)
		{
			break;
		}
	}

	if (ok)
	{
		cout << s << endl;
	} else {
		cout << -1 << " " << -1 << " " << -1 << endl;
	}

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:39:2: error: expected '}' at end of input
   39 | }
      |  ^
a.cc:6:1: note: to match this '{'
    6 | {
      | ^
Language: C++

#include<iostream>
using namespace std;

int main(){
    int n,y;
    cin>>n>>y;

    int m[3]={-1};
    
    for(int i=0;i<n;i++){
        for(int j=0;j<n;j++){
            if(y==10000*i+5000*j+1000*(n-i-j)){
                m[0]=i;
                m[1]=j
                m[2]=n-i-j;
                break;
            }
        }
    }
    cout<<m[0]<<" "<<m[1]<<" "<<m[2]<<endl;

    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:23: error: expected ';' before 'm'
   14 |                 m[1]=j
      |                       ^
      |                       ;
   15 |                 m[2]=n-i-j;
      |                 ~
Language: C++

#include <iostream>
using namespace std;
int main(){
  long long int n,a;
  cin>>n>>a;
  
  for(int i=0;i=<n;i++){
    for(int m=0;m=<n;m++){
      int l=n-i-m;
      if(l>=0&&10000*i+5000*m+1000*l==a){
        cout<<i<<" "<<m<<" "<<l<<endl;
        return 0;
      }
    }
  }
  cout<<"-1 -1 -1"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: expected primary-expression before '<' token
    7 |   for(int i=0;i=<n;i++){
      |                 ^
a.cc:8:19: error: expected primary-expression before '<' token
    8 |     for(int m=0;m=<n;m++){
      |                   ^
Language: C++

#include <iostream>
using namespace std;
int main(){
  int n,a;
  cin>>n>>a;
  
  for(int i=0;i<n;i++){
    for(int m=0;m\0<n;m++){
      int l=n-i-m;
      if(l<=0&&10000*i+5000*m+1000*l==a){
        cout<<i<<" "<<m<<" "<<l<<endl;
      }
    }
  }
}

Compiler output:
a.cc:8:18: error: stray '\' in program
    8 |     for(int m=0;m\0<n;m++){
      |                  ^
a.cc: In function 'int main()':
a.cc:8:18: error: expected ';' before numeric constant
    8 |     for(int m=0;m\0<n;m++){
      |                  ^~
      |                  ;
a.cc:8:22: error: expected ')' before ';' token
    8 |     for(int m=0;m\0<n;m++){
      |        ~             ^
      |                      )
a.cc:8:23: error: 'm' was not declared in this scope
    8 |     for(int m=0;m\0<n;m++){
      |                       ^
Language: C++

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

int main() {
  int n, y, sum;
  int l = 0, m = 0, o = 0;

  scanf("%d %d", &n, &y);

  for (l = 0; l <= y / 10000; l++) {
    for (m = 0; m <= (y - (10000 * l)) / 5000; m++) {
      for (o = 0; o <= (y - (10000 * l + 5000 * m)) / 1000; o++) {
        sum = (10000 * l) + (5000 * m) + (1000 * o);
        if (sum == y && (l + m + o) == n) {
          printf("%d %d %d\n", l, m, o);
          return 0;
        }       
      }
    }
  }

  printf("-1 -1 -1\n");
  return 0;

}

}

Compiler output:
a.cc:27:1: error: expected declaration before '}' token
   27 | }
      | ^
Language: Java

public class Main {

    private static Scanner sc = new Scanner(System.in);

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

    private void solve() {
        try {
            int n = sc.nextInt();
            int y = sc.nextInt();
            int a = 0;
            int b = 0;
            int c = 0;

            int x = y - 10000 * a + 5000 * b + 1000 * c;

            for (int i = 0; i < n; i++) {
                for (int j = 0; j < n; j++) {
                    int k = n - i - j;
                    if (k < 0) {
                        continue;
                    }
                    if (i * 10000 + j * 5000 + 1000 * (n - i - j) == y) {
                        System.out.println(i + " " + j + " " + (n - i - j));
                        return;
                    }
                }
            }
            System.out.println("-1 -1 -1");
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}


Compiler output:
Main.java:3: error: cannot find symbol
    private static Scanner sc = new Scanner(System.in);
                   ^
  symbol:   class Scanner
  location: class Main
Main.java:3: error: cannot find symbol
    private static Scanner sc = new Scanner(System.in);
                                    ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C++

#include <iostream>
using namespace std;


int main(){
  int N, Y;
  cin >> N >> Y;
  
  for(int i; i< N; i++){
  	for(int j; j < N-i; j++){
    	if((10000 * i + 5000 * j + (N-i-j)*1000) == Y){ 
          cout << i << " " << j << " " << k <<endl;
          return 0;
        }
    }
  }
  cout << "-1 -1 -1"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:43: error: 'k' was not declared in this scope
   12 |           cout << i << " " << j << " " << k <<endl;
      |                                           ^
Language: C++

#include <iostream>
using namespace std;

int main(){
  int N, Y;
  cin >> N >> Y;
  
  for(int a = 0; a < N; a++){
    for(int b = 0; b < N; b++){
      int c = N - a - b;
      if(10000*a + 5000*b + 1000*c == Y){
        res10000 = a;
        res5000 = b;
        res1000 = c;
      }
      else {
        res10000 = -1;
        res5000 = -1;
        res1000 = -1;
      }
    }
  }
        
      cout << res10000 << "" << res5000 << "" << res1000 << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:9: error: 'res10000' was not declared in this scope
   12 |         res10000 = a;
      |         ^~~~~~~~
a.cc:13:9: error: 'res5000' was not declared in this scope
   13 |         res5000 = b;
      |         ^~~~~~~
a.cc:14:9: error: 'res1000' was not declared in this scope
   14 |         res1000 = c;
      |         ^~~~~~~
a.cc:17:9: error: 'res10000' was not declared in this scope
   17 |         res10000 = -1;
      |         ^~~~~~~~
a.cc:18:9: error: 'res5000' was not declared in this scope
   18 |         res5000 = -1;
      |         ^~~~~~~
a.cc:19:9: error: 'res1000' was not declared in this scope
   19 |         res1000 = -1;
      |         ^~~~~~~
a.cc:24:15: error: 'res10000' was not declared in this scope
   24 |       cout << res10000 << "" << res5000 << "" << res1000 << endl;
      |               ^~~~~~~~
a.cc:24:33: error: 'res5000' was not declared in this scope
   24 |       cout << res10000 << "" << res5000 << "" << res1000 << endl;
      |                                 ^~~~~~~
a.cc:24:50: error: 'res1000' was not declared in this scope
   24 |       cout << res10000 << "" << res5000 << "" << res1000 << endl;
      |                                                  ^~~~~~~
Language: C++

#include <iostream>
using namespace std;

int main(){
  int N, Y;
  cin >> N >> Y;
  
  for(int a = 0; a < N; i++){
    for(int b = 0; b < N; i++){
      int c = N - a - b;
      if(10000*a + 5000*b + 1000*c == Y){
        cout << a << "" << b << "" << c << endl;
      }
      else cout << -1 << "" << -1 << "" << -1 << endl;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:25: error: 'i' was not declared in this scope
    8 |   for(int a = 0; a < N; i++){
      |                         ^
Language: C++

<?php
fscanf(STDIN, "%d %d", $N, $Y);

for ($k10 = 0; $k10 * 10000 <= $Y; $k10++) {
    for ($k5 = 0; $k10 * 10000 + $k5 * 5000 <= $Y; $k5++) {
        $k1 = ($Y - $k10 * 10000 - $k5 * 5000) / 1000;
        // printf("k10:%d k5:%d k1:%d\n", $k10, $k5, $k1);
        if ($k10 + $k5 + $k1 == $N) {
            echo "{$k10} {$k5} {$k1}" . PHP_EOL;
            exit;
        }
    }
}
echo "-1 -1 -1" . PHP_EOL;


Compiler output:
a.cc:1:1: error: expected unqualified-id before '<' token
    1 | <?php
      | ^
a.cc:4:1: error: expected unqualified-id before 'for'
    4 | for ($k10 = 0; $k10 * 10000 <= $Y; $k10++) {
      | ^~~
a.cc:4:16: error: '$k10' does not name a type
    4 | for ($k10 = 0; $k10 * 10000 <= $Y; $k10++) {
      |                ^~~~
a.cc:4:36: error: '$k10' does not name a type
    4 | for ($k10 = 0; $k10 * 10000 <= $Y; $k10++) {
      |                                    ^~~~
a.cc:14:1: error: 'echo' does not name a type
   14 | echo "-1 -1 -1" . PHP_EOL;
      | ^~~~
Language: C++

#include <iostream>
using namespace std;

int main(){
  int n,y;
  cin>>n>>y;
  for(int i=0;i<=n;i++){
    for(int j=0;i+j<=n;j++){
      if(10000*i+5000*j+1000*(n-i-j)==y){
        cout<<i<<" "<<j<<" "<<k<<endl;
        return 0;
      }
    }
  }
  cout<<"-1 -1 -1"<<endl;
}
        


Compiler output:
a.cc: In function 'int main()':
a.cc:10:31: error: 'k' was not declared in this scope
   10 |         cout<<i<<" "<<j<<" "<<k<<endl;
      |                               ^
Language: Java

import java.util.*;
public class Main{
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
  int N = sc.nextInt();
  int Y = sc.nextInt();
  int x = -1; int y = -1; int z = -1;
  for(int i = 0;i < N;i++){
    for(int j = 0;j < N-i;j++){
      for(int k = 0;k < N-i-j;j++){
        if(10000*i + 5000*j + 1000*k){
          x = i;y = j;z = k;
        }
      }
    }
  }
  System.out.println(x+""+y+""+z);
}}


Compiler output:
Main.java:11: error: incompatible types: int cannot be converted to boolean
        if(10000*i + 5000*j + 1000*k){
                            ^
1 error
Language: Java

import java.util.*;
public class Main{
public static void main(String[] args){
Scanner sc = new Scanner(System.in);
  int N = sc.nextint();
  int Y = sc.nextInt();
  int x = -1; int y = -1; int z = -1;
  for(int i = 0;i < N;i++){
    for(int j = 0;j < N-i;j++){
      for(int k = 0;k < N-i-j;j++){
        if(10000*i + 5000* j + 1000*k){
          x = i;y = j;z = k;
        }
      }
    }
  }
  System.out.println(x+""+y+""+z);
}}

Compiler output:
Main.java:5: error: cannot find symbol
  int N = sc.nextint();
            ^
  symbol:   method nextint()
  location: variable sc of type Scanner
Main.java:11: error: incompatible types: int cannot be converted to boolean
        if(10000*i + 5000* j + 1000*k){
                             ^
2 errors
Language: C++

N, Y = map(int, input().split())

for i in range(N + 1):
    for j in range(N + 1):
        if i + j + max(0, (Y - 10000 * i - 5000 * j)) // 1000 == N:
            print(i, j, (Y - 10000 * i - 5000 * j) // 1000)
            break
    else:
        continue
    break
else:
    print(-1, -1, -1)


Compiler output:
a.cc:1:1: error: 'N' does not name a type
    1 | N, Y = map(int, input().split())
      | ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  int N,Y;
  cin>>N>>Y;
  int flag=0;
  int ans[3]={0};
  for(int a=0;a<=N;a++){
    for(int b=0;b<=N;b++){
      int c=N-a-b;
      int sum=10000*a+5000*b+1000*c;
      if(sum==Y){
        ans[0]=a;
        ans[1]=b;
        ans[2]=c;
        flag++;
      }
   }
  }
  if(flag==0){
    ans[0]=-1;
    ans[1]=-1;
    ans[2]=-1;
  }
  printf("%d %d %d\n",a[0],a[1],a[2]);
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:23: error: 'a' was not declared in this scope
   25 |   printf("%d %d %d\n",a[0],a[1],a[2]);
      |                       ^
Language: C++

    #include<iostream>
    using namespace std;
    int main(){
      int N,Y;
      cin>>N>>Y;
      int flag=0;
      int ans[3]={0};
      for(int a=0;a<=N;a++){
        for(int b=0;b<=N;b++){
          int c=N-a-b;
          int sum=10000*a+5000*b+1000*c;
          if(sum==Y){
            ans[0]=a;
            ans[1]=b;
            ans[2]=c;
            flag++;
          }
       }
      }
      if(flag==0)ans={-1};
      printf("%d %d %d\n",a[0],a[1],a[2]);
      return 0;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:20:21: error: assigning to an array from an initializer list
   20 |       if(flag==0)ans={-1};
      |                  ~~~^~~~~
a.cc:21:27: error: 'a' was not declared in this scope
   21 |       printf("%d %d %d\n",a[0],a[1],a[2]);
      |                           ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  int N,Y;
  cin>>N>>Y;
  int flag=0;
  int ans[3]={0};
  for(int a=0;a<=N;a++){
    for(int b=0;b<=N;b++){
      int c=N-a-b;
      int sum=10000*a+5000*b+1000*c;
      if(sum==Y){
        ans={a b c};flag++;
      }
   }
  }
  if(flag==0)ans={-1};
  printf("%d %d %d\n",a[0],a[1],a[2]);
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:16: error: expected '}' before 'b'
   13 |         ans={a b c};flag++;
      |             ~  ^
a.cc:13:12: error: assigning to an array from an initializer list
   13 |         ans={a b c};flag++;
      |         ~~~^~~~~
a.cc: At global scope:
a.cc:17:3: error: expected unqualified-id before 'if'
   17 |   if(flag==0)ans={-1};
      |   ^~
a.cc:18:9: error: expected constructor, destructor, or type conversion before '(' token
   18 |   printf("%d %d %d\n",a[0],a[1],a[2]);
      |         ^
a.cc:19:3: error: expected unqualified-id before 'return'
   19 |   return 0;
      |   ^~~~~~
a.cc:20:1: error: expected declaration before '}' token
   20 | }
      | ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  int N,Y;
  cin>>N>>Y;
  for(int a=0;a<=N;a++){
    for(int b=0;b<=N;b++){
      int c=N-a-b;
      sum=10000*a+5000*b+1000*c;
      if(sum==Y)cout<<a<<" "<<b<<" "<<c<<endl;
    }
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:7: error: 'sum' was not declared in this scope
    9 |       sum=10000*a+5000*b+1000*c;
      |       ^~~
Language: C++

#include <bits/stdc++.h>
#define FOR(i, m, n) for(int i = m;i < n;i++)
#define FORR(i, m, n) for(int i = m;i >= n;i--)
#define SORT(v, n) sort(v, v+n);
#define SORTR(v,n) sort(v, v+n, greater<int>());
#define SORTPairSecond(v, n) sort(v, v+n, pairCompareSecond);
#define int long long    // %d=>%lld, 1<<n  => 1LL<<n
#define pb push_back

using namespace std;
typedef long long ll;

typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef pair<int, pii> piii;
typedef pair<ll, pll> plll;
bool pairCompareSecond(const pii& firstEl, const pii& secondEl) {
    return firstEl.second > secondEl.second;
}

const ll MOD = 1000000007;
const int INF = 1000000007;
// const int INF = 0x3f3f3f3f;
const ll LLINF = 0x3f3f3f3f3f3f3f3f;
// const ll LLINF = 1LL << 50;
const double PI = acos(-1);
const double EPS = 0.000000001;


double n, y;

signed main(){
    ios::sync_with_stdio(0);
    cin >> n >>  y;

    if(y%1000!=0 || n*10000<y || n*1000>y){
        cout<< "-1 -1 -1"<< endl;
        return 0;
    }

    for(int i = 0;i < n;i++){
        for(int j = 0;j < n-i;j++){
            if((y-i* 10000+j* 5000)/1000.0 == n-i-j){
                cout<< i<< " "<< j<< " "<< n-i-j<< endl;
                return 0;
            }
        }
    }


    cout<< "-1 -1 -1"<< endl;

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:36:9: error: invalid operands of types 'double' and 'int' to binary 'operator%'
   36 |     if(y%1000!=0 || n*10000<y || n*1000>y){
      |        ~^~~~~
      |        | |
      |        | int
      |        double
Language: C++

#include <iostream>
#include <iomanip>
#include <vector>
#include <queue>
#include <map>
#include <string>
#include <math.h>
#include <algorithm>
using namespace std;
int main() {
	int n, y;
	cin >> n >> y;
	for (int i = 0; i <= n; i++) {
		for (int j = 0; i + j <= n; j++) {
			int k = n - i + j;
			if (10000 * i + 5000 * j * 1000 * k == y) {
				cout << i << ' ' << j << ' ' << k << endl;
				return 0;
			}
		}
	}
	cout << "-1 -1 -1" << endl;
	return 0;
}
#include <iostream>
#include <iomanip>
#include <vector>
#include <queue>
#include <map>
#include <string>
#include <math.h>
#include <algorithm>
using namespace std;
int main() {
	int n, y;
	cin >> n >> y;
	for (int i = 0; i <= n; i++) {
		for (int j = 0; i + j <= n; j++) {
			int k = n - i + j;
			if (10000 * i + 5000 * j + 1000 * k == y) {
				cout << i << ' ' << j << ' ' << k << endl;
				return 0;
			}
		}
	}
	cout << "-1 -1 -1" << endl;
	return 0;
}

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

#include <iostream>
using namespace std;

int main(){
	int N,Y,Z,A=0,x,y,z;

	cin >> N >> Y;

	Z = Y;
	x = Z/10000;
	Z = Z%10000;
	y += Z/5000;
	Z = Z%5000;
	z += Z/1000;
	A = x+y+z;
	if(A!=N) {cout << "-1 -1 -1";}
	else {cout << x << " " << y << " " << z;
}

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

#include<stdio.h>

int main() {


	int i, g, s;
	int n, y;
	int x = 0;


	scanf("%d%d", &n, &y);

	
	for (i = n; i >= 0; i--) {

	
		if (y == 10000 * i) {
			if (i == n) {
				printf("%d 0 0 ", i);
				x = 1;

				goto out;

			}
		}
		if (10000 * i<y) {

			for (g = n - i; g >= 0; g--) {




				if (10000 * i + 5000 * g == y && i + g == n) {


					printf("%d %d 0 ", i, g);
					x = 1;

					goto out;
				}
				if (10000 * i + 5000 * g < y) {

					for (s = n - g - i; s >= 0; s--) {


						if (s + g + i == n && 1000 * s + 5000 * g + 10000 * i == y) {
							printf("%d %d %d", i, g, s);
							x = 1;

							goto out;
						}
					}
				
			}

		}

	}

out:
	if (x == 0) {
		printf("-1 -1 -1");

	}


}




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

#include <iostream>
#include <set>
using namespace std;
int main()
{
    int n,Y;
    while(cin>>n>>Y){
        Y/=1000;
        if(n*10<Y||n>Y){
            cout<<-1<<" "<<-1<<" "<<-1<<endl;
            continue;
        }
        for(int i=x;i>=0;i--){
            for(int j=n-i;j>=0;j--){
                for(int l=n-i-j;l>=0;l--){
                    if(i*10+j*5+l==Y){
                        cout<<i<<" "<<j<<" "<<l<<endl;
                        flag=1;
                        break;
                    }
                }
                if(flag) break;
            }
            if(flag) break;
        }
        if(!flag) cout<<-1<<" "<<-1<<" "<<-1<<endl;
    }
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:19: error: 'x' was not declared in this scope
   13 |         for(int i=x;i>=0;i--){
      |                   ^
a.cc:18:25: error: 'flag' was not declared in this scope
   18 |                         flag=1;
      |                         ^~~~
a.cc:22:20: error: 'flag' was not declared in this scope
   22 |                 if(flag) break;
      |                    ^~~~
a.cc:24:16: error: 'flag' was not declared in this scope
   24 |             if(flag) break;
      |                ^~~~
a.cc:26:13: error: 'flag' was not declared in this scope
   26 |         if(!flag) cout<<-1<<" "<<-1<<" "<<-1<<endl;
      |             ^~~~
Language: C

int x = 0;


	scanf("%d%d", &n, &y);
	if (1 > n || n > 2000) {
		goto out;
	}
	if (y < 1000 || y > 2 * pow(10,7) || y%1000!=0) {
		goto out;
	}
	if (10000 * n < y) {

		goto out;

	}


	for (i = n; i >= 0; i--) {


		if (y == 10000 * i) {
			if (i == n) {
				printf("%d 0 0 ", i);
				x = 1;

				goto out;

			}
		}
		if (10000 * i<y) {

			for (g = n - i; g >= 0; g--) {




				if (10000 * i + 5000 * g == y && i + g == n) {


					printf("%d %d 0\n", i, g);
					x = 1;

					goto out;
				}
				if (10000 * i + 5000 * g < y) {

					for (s = n - g - i; s >= 0; s--) {


						if (s + g + i == n && 1000 * s + 5000 * g + 10000 * i == y) {
							printf("%d %d %d", i, g, s);
							x = 1;

							goto out;
						}
						if (1000 * s + 5000 * g + 10000 * i < y) {

							goto out;
						}
						if (1000 * s + 5000 * g + 10000 * i > y) {

							break;

						}



					}
				}
			}

		}

	}

out:
	if (x == 0) {
		printf("-1 -1 -1");

	}


}









Compiler output:
main.c:4:15: error: expected declaration specifiers or '...' before string constant
    4 |         scanf("%d%d", &n, &y);
      |               ^~~~~~
main.c:4:23: error: expected declaration specifiers or '...' before '&' token
    4 |         scanf("%d%d", &n, &y);
      |                       ^
main.c:4:27: error: expected declaration specifiers or '...' before '&' token
    4 |         scanf("%d%d", &n, &y);
      |                           ^
main.c:5:9: error: expected identifier or '(' before 'if'
    5 |         if (1 > n || n > 2000) {
      |         ^~
main.c:8:9: error: expected identifier or '(' before 'if'
    8 |         if (y < 1000 || y > 2 * pow(10,7) || y%1000!=0) {
      |         ^~
main.c:11:9: error: expected identifier or '(' before 'if'
   11 |         if (10000 * n < y) {
      |         ^~
main.c:18:9: error: expected identifier or '(' before 'for'
   18 |         for (i = n; i >= 0; i--) {
      |         ^~~
main.c:18:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '>=' token
   18 |         for (i = n; i >= 0; i--) {
      |                       ^~
main.c:18:30: error: expected '=', ',', ';', 'asm' or '__attribute__' before '--' token
   18 |         for (i = n; i >= 0; i--) {
      |                              ^~
main.c:76:4: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token
   76 | out:
      |    ^
main.c:83:1: error: expected identifier or '(' before '}' token
   83 | }
      | ^
Language: C++

#include<iostream>
#include<cmath>
#include<algorithm>
using namespace std;
int main(){
    long long int N,Y;
    cin >> N >> Y;
    for(int z=0;z<N-(x+y);z++){
        for(int y=0:y<N-(x+z);y++){
            for(int x=0;x<N-(y+z);x++){
                if(Y==x*1000+y*5000+z*100000){
                    cout << x << " " << y << " " << z << endl;
                    return 0;
                }
            }
        }
    }
    cout << "-1 -1 -1\n";
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:22: error: 'x' was not declared in this scope
    8 |     for(int z=0;z<N-(x+y);z++){
      |                      ^
a.cc:8:24: error: 'y' was not declared in this scope
    8 |     for(int z=0;z<N-(x+y);z++){
      |                        ^
a.cc:9:18: error: initializer in range-based 'for' loop
    9 |         for(int y=0:y<N-(x+z);y++){
      |                  ^
a.cc:9:30: error: expected ')' before ';' token
    9 |         for(int y=0:y<N-(x+z);y++){
      |            ~                 ^
      |                              )
Language: C++

#include <cstdlib>
#include <cstring>
#include <cmath>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <time.h>
#include <vector>
//#include <random>
//#include <unordered_set>
#include <complex>
using namespace std;
int main()
{
    long long n,y,i,j,k;
    cin>>n>>y;
    for(i=0;i<=n;i++) 
    {
 //       if((i*10000)>y) break;
        for(j=0;j<=n-i;j++) 
        {
                k=n-i-j;

                if(((i*10000)+(j*5000)+(k*1000))==y)
                {
                    cout<<i<<" "<<j<<" "<<k;
                    system ("pause");
                    return 0;
                }

   //             if(((i*10000)+(j*5000)+(k*1000))>y) break;
            
        }
    }
    cout<<"-1 -1 -1";
    system ("pause"); 
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:19:5: error: 'cin' was not declared in this scope
   19 |     cin>>n>>y;
      |     ^~~
a.cc:15:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
   14 | #include <complex>
  +++ |+#include <iostream>
   15 | using namespace std;
a.cc:29:21: error: 'cout' was not declared in this scope
   29 |                     cout<<i<<" "<<j<<" "<<k;
      |                     ^~~~
a.cc:29:21: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:38:5: error: 'cout' was not declared in this scope
   38 |     cout<<"-1 -1 -1";
      |     ^~~~
a.cc:38:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
 
using namespace std;
using namespace __gnu_pbds;
 
#define fi first
#define se second
#define mp make_pair
#define pb push_back
#define fbo find_by_order
#define ook order_of_key
 
typedef long long ll;
typedef pair<int,int> ii;
typedef vector<int> vi;
typedef long double ld; 
typedef tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update> pbds;
typedef set<int>::iterator sit;
typedef map<int,int>::iterator mit;
typedef vector<int>::iterator vit;

// template from zscoder

int main()
{
    ios_base::sync_with_stdio(0); cin.tie(0);
    //freopen("input.txt","r",stdin); freopen("output.txt","w",stdout);
    ll n,y;
  cin >> n >> y;
  for(int i = 0; i <= n; i++)
  {
    for(int j = 0; j <= n; j++)
    {
      int k = n-i-j;
      if((i*10000+j*5000+k*1000)==y)
      {
        cout << i << " " j << " " << k << endl;
        return 0;
      }
    }
  }
  cout << -1 << " " << -1 << " " << -1 << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:39:25: error: expected ';' before 'j'
   39 |         cout << i << " " j << " " << k << endl;
      |                         ^~
      |                         ;
Language: C++

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

int main(){
    int n,y;
    scanf("%d%d",&n,&y);

    for(int i=0;i<=n;i++){
        if(y<i*10000)break;

        for(int j=0;j<=n;j++){
            if(n<i+j)break;
            if(y<i*10000+j*5000)break;

            int k=n-i-j;

            if(10000*i+5000*j+1000*k==y){
                printf("%d %d %d",i,j,k);
                return 0;
            }

            }
        }
    }
    //printf("-1 -1 -1");
    return 0;
}

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

#include<bits/stdc++.h>
using namespace std;
int n,m;
bool flag=1;
int main() {
	cin>>n>>m;
	for(int x=0; x<=n; x++)
		for(int y=0,z; y<=n-x; y++){
z=n-x-y;
				if(x*10000+y*5000+z*1000==m&&x+y+z==n) {
					cout<<x<<' '<<y<<' '<<z<<endl;
					flag=0;
					return 0;
				}
	if(flag)cout<<"-1 -1 -1";
	return 0;
}

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

#include<bits/stdc++.h>
using namespace std;
int n,m;
bool flag=1;
int main() {
	cin>>n>>m;
	for(int x=0; x<=n; x++)
		for(int y=0，z; y<=n; y++)
z=n-x-y;
				if(x*10000+y*5000+z*1000==m&&x+y+z==n) {
					cout<<x<<' '<<y<<' '<<z<<endl;
					flag=0;
					return 0;
				}
	if(flag)cout<<"-1 -1 -1";
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:27: error: unable to find numeric literal operator 'operator""\U0000ff0cz'
    8 |                 for(int y=0，z; y<=n; y++)
      |                           ^~~~
a.cc:9:1: error: 'z' was not declared in this scope
    9 | z=n-x-y;
      | ^
a.cc:10:36: error: 'x' was not declared in this scope
   10 |                                 if(x*10000+y*5000+z*1000==m&&x+y+z==n) {
      |                                    ^
a.cc:10:44: error: 'y' was not declared in this scope; did you mean 'yn'?
   10 |                                 if(x*10000+y*5000+z*1000==m&&x+y+z==n) {
      |                                            ^
      |                                            yn
a.cc:10:51: error: 'z' was not declared in this scope
   10 |                                 if(x*10000+y*5000+z*1000==m&&x+y+z==n) {
      |                                                   ^
Language: C++

#include <iostream>
#include<bits/stdc++.h>
using namespace std;
int dp[20000];

int main()
{
long long n,m;
cin>>n>>m;
for(long long i=0;;i++)
{

        long long x=10000*i;
      if(x>m)
        break;
    for(long long j=0;;j++)
    {

        long long y=x+j*5000;
        if(y>m)
            break;
          if(y==m)
          {
              
          
       y-=m;
       long long p=y/1000;
        if(p+i+j==)
        {
            cout << i<<" "<< j << " " << p<<endl;
            return 0;
        }
          }

    }
}
cout <<"-1 -1 -1"<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:28:19: error: expected primary-expression before ')' token
   28 |         if(p+i+j==)
      |                   ^
Language: C++

#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
#include <stack>
#include <queue>
#include <set>
#include <map>
using namespace std;
#define vec vector<int>
#define pb push_back
#define lis list<int> lst(1000)


int main(){
	int N,Y;

	scanf("%d%d",&N&Y);

	for(int a=0;a<=N;a++){
		for(int b=0;b<=(N-a);b++){
			for(int c=0;c<=((N-a)-b);c++){
				if ((a*10000+b*5000+C*1000)==Y){
					cout << a << " " << b << " " << c << endl;
					return 0;
				}
			}
		}
	}

 cout << "-1 -1 -1" << endl;
 return 0;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:24: error: invalid operands of types 'int*' and 'int' to binary 'operator&'
   21 |         scanf("%d%d",&N&Y);
      |                      ~~^~
      |                      |  |
      |                      |  int
      |                      int*
a.cc:26:53: error: 'C' was not declared in this scope
   26 |                                 if ((a*10000+b*5000+C*1000)==Y){
      |                                                     ^
Language: Java

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int Y = sc.nextInt();

		if(Y%1000!=0) {
			System.out.println("-1 -1 -1");
			return;
		}

		for(int i = 0; i <= N; i++) {
			for(int j = 0; j + i <= N; j++) {
				for(int k = 0; k + j + i<= N; k++) {
					if(10*k+5*j+i == Y/1000) {
						System.out.println(k + " " + j + " " + i);
						return;
					}
				}
			}
		}
		System.out.println("-1 -1 -1");
	}

}

Compiler output:
Main.java:4: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:4: error: cannot find symbol
		Scanner sc = new Scanner(System.in);
		                 ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C++

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

int n,y;
int main()
{
	cin>>n>>y;
	for(int i=0;i<=n;i++)
		for(int j=0;j<=n-i;j++)
		{
			int p=n-i-j;
			if(10000*i+5000*j+1000*p==y){
				cout<<i<<' '<<j<<' '<<p;
				return 0;
		}
	cout<<"-1 -1 -1";
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:2: error: expected '}' at end of input
   18 | }
      |  ^
a.cc:6:1: note: to match this '{'
    6 | {
      | ^
Language: C++

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

int n,y;
int main()
{
	cin>>n>>y;
	for(int i=0;i<=n;i++)
		for(int j=0;j<=n-i;j++)
		{
			int p=n-i-j;
			if(10000*i+5000*j+1000*k==y){
				cout<<i<<' '<<j<<' '<<k;
				return 0;
		}
	cout<<"-1 -1 -1";
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:48: error: 'k' was not declared in this scope
   12 |                         if(10000*i+5000*j+1000*k==y){
      |                                                ^
a.cc:18:2: error: expected '}' at end of input
   18 | }
      |  ^
a.cc:6:1: note: to match this '{'
    6 | {
      | ^
Language: C++

#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
#include <stack>
#include <queue>
#include <set>
#include <map>
using namespace std;
#define vec vector<int>
#define pb push_back
#define lis list<int> lst(1000)


int main(){
	int a,b,c,d,e,f,g;
	char o,p,q,r,s,t,u;
	int ans;

	scanf("%d%d",&a,&b);

	for(int m=0;m=<a;m++){
		for(int g=0;g=<a;g++){
			for(int s=0;s=<a;s++){
				if((m*10000+g*5000+s*1000)==b){
					cout << m << " " << g << " " << s << endl;
					return 0;
				}
			}
		}
	}	

	cout << "-1" << " " << "-1" << " " << "-1" << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:23: error: expected primary-expression before '<' token
   25 |         for(int m=0;m=<a;m++){
      |                       ^
a.cc:26:31: error: expected primary-expression before '<' token
   26 |                 for(int g=0;g=<a;g++){
      |                               ^
a.cc:27:39: error: expected primary-expression before '<' token
   27 |                         for(int s=0;s=<a;s++){
      |                                       ^
Language: C++

#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
#include <stack>
#include <queue>
#include <set>
#include <map>
using namespace std;
#define vec vector<int>
#define pb push_back
#define lis list<int> lst(1000)


int main(){
	int a,b,c,d,e,f,g;
	char o,p,q,r,s,t,u;
	int ans;

	scanf("%d%d",&a,&b);

	if()
	for(int m=0;m<2001;m++){
		for(int g=0;g<4001;g++){
			for(int s=0;s<20001;s++){
				if((m+g+s)==a and (m*10000+g*5000+s*1000)==b){
					cout << m << " " << g << " " << s << endl;
					break;
				}
			}
			if((m+g+s)==a and (m*10000+g*5000+s*1000)==b){
					cout << m << " " << g << " " << s << endl;
					break;
				}
		}
		if((m+g+s)==a and (m*10000+g*5000+s*1000)==b){
				cout << m << " " << g << " " << s << endl;
				break;
			}
	}	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:12: error: expected primary-expression before ')' token
   25 |         if()
      |            ^
Language: C++

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

int main() {
	set<int> S;
	int n;
	cin >> n;
	for (int i = 0; i < n; i++) {
		int d;
		cin >> d;
		S.insert(d);
	}
	cout << S.size() << endl;
	return 0;
}#include<iostream>
#include<set>
using namespace std;

int main() {
	set<int> S;
	int n;
	cin >> n;
	for (int i = 0; i < n; i++) {
		int d;
		cin >> d;
		S.insert(d);
	}
	cout << S.size() << endl;
	return 0;
}

Compiler output:
a.cc:16:2: error: stray '#' in program
   16 | }#include<iostream>
      |  ^
a.cc:16:3: error: 'include' does not name a type
   16 | }#include<iostream>
      |   ^~~~~~~
a.cc:20:5: error: redefinition of 'int main()'
   20 | int main() {
      |     ^~~~
a.cc:5:5: note: 'int main()' previously defined here
    5 | int main() {
      |     ^~~~
Language: C++

/**OOO**/ #include<bits/stdc++.h> #define ll long long #define ull unsigned long long #define mems(x,y) memset(x,y,sizeof(x)) #define pf printf #define sc scanf using namespace std; int main()
{ //ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); ll n,y,a,b,c; cin>>n>>y; if(y%10000==0 && y/10000==n)cout<<y/10000<<" "<<0<<" "<<0<<endl; else if(y%5000==0 && y/5000==n)cout<<0<<" "<<y/5000<<" "<<0<<endl; else if(y%1000==0 && y/1000==n)cout<<0<<" "<<0<<" "<<y/1000<<endl; else{ for(int i=0;i<=n;i++){ a=10000*i; for(int j=0;j<=n-i;j++){ b=5000*j; for(int k=0;k<=n-i-j;k++){ c=1000*k; if(a+b+c==y && i+j+k==n){ cout<<i<<" "<<j<<" "<<k<<endl; return 0; } } } } cout<<-1<<" "<<-1<<" "<<-1<<endl; } return 0; }

Compiler output:
a.cc:1:35: warning: extra tokens at end of #include directive
    1 | /**OOO**/ #include<bits/stdc++.h> #define ll long long #define ull unsigned long long #define mems(x,y) memset(x,y,sizeof(x)) #define pf printf #define sc scanf using namespace std; int main()
      |                                   ^
a.cc:2:1: error: expected unqualified-id before '{' token
    2 | { //ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); ll n,y,a,b,c; cin>>n>>y; if(y%10000==0 && y/10000==n)cout<<y/10000<<" "<<0<<" "<<0<<endl; else if(y%5000==0 && y/5000==n)cout<<0<<" "<<y/5000<<" "<<0<<endl; else if(y%1000==0 && y/1000==n)cout<<0<<" "<<0<<" "<<y/1000<<endl; else{ for(int i=0;i<=n;i++){ a=10000*i; for(int j=0;j<=n-i;j++){ b=5000*j; for(int k=0;k<=n-i-j;k++){ c=1000*k; if(a+b+c==y && i+j+k==n){ cout<<i<<" "<<j<<" "<<k<<endl; return 0; } } } } cout<<-1<<" "<<-1<<" "<<-1<<endl; } return 0; }
      | ^
Language: C++

/**OOO**/ #include<bits/stdc++.h> #define ll long long #define ull unsigned long long #define mems(x,y) memset(x,y,sizeof(x)) #define pf printf #define sc scanf using namespace std; int main()
{  ll n,y,a,b,c; cin>>n>>y; if(y%10000==0 && y/10000==n)cout<<y/10000<<" "<<0<<" "<<0<<endl; else if(y%5000==0 && y/5000==n)cout<<0<<" "<<y/5000<<" "<<0<<endl; else if(y%1000==0 && y/1000==n)cout<<0<<" "<<0<<" "<<y/1000<<endl; else{ for(int i=0;i<=n;i++){ a=10000*i; for(int j=0;j<=n-i;j++){ b=5000*j; for(int k=0;k<=n-i-j;k++){ c=1000*k; if(a+b+c==y && i+j+k==n){ cout<<i<<" "<<j<<" "<<k<<endl; return 0; } } } } cout<<-1<<" "<<-1<<" "<<-1<<endl; } return 0; }

Compiler output:
a.cc:1:35: warning: extra tokens at end of #include directive
    1 | /**OOO**/ #include<bits/stdc++.h> #define ll long long #define ull unsigned long long #define mems(x,y) memset(x,y,sizeof(x)) #define pf printf #define sc scanf using namespace std; int main()
      |                                   ^
a.cc:2:1: error: expected unqualified-id before '{' token
    2 | {  ll n,y,a,b,c; cin>>n>>y; if(y%10000==0 && y/10000==n)cout<<y/10000<<" "<<0<<" "<<0<<endl; else if(y%5000==0 && y/5000==n)cout<<0<<" "<<y/5000<<" "<<0<<endl; else if(y%1000==0 && y/1000==n)cout<<0<<" "<<0<<" "<<y/1000<<endl; else{ for(int i=0;i<=n;i++){ a=10000*i; for(int j=0;j<=n-i;j++){ b=5000*j; for(int k=0;k<=n-i-j;k++){ c=1000*k; if(a+b+c==y && i+j+k==n){ cout<<i<<" "<<j<<" "<<k<<endl; return 0; } } } } cout<<-1<<" "<<-1<<" "<<-1<<endl; } return 0; }
      | ^
Language: C

/**OOO**/
#include<bits/stdc++.h>
#define ll long long
#define ull unsigned long long
#define mems(x,y) memset(x,y,sizeof(x))
#define pf printf
#define sc scanf
using namespace std;


int main()
{

    int t;
    cin>>t;
    while(t--)
    {
        ll n;
        scanf("%lld",&n);
        ll a=2*n + 1;
        ll b=n+1;
        ll c=n*a*b;
        ll first_half=c/6;
        ll second_half=first_half-(n*n);
        printf("%lld\n",first_half+second_half);

    }

return 0;
}


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

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

int main()
{
int n, y;
cin >> n >> y;
for(int i = 0; i <= n; i++)
{
for(int j = n - i; j <= n; j++)
{
if(y == 10000 * i + 5000 * j + 1000 * (n - i -j)
{
cout << i << " " << j << " " << (n - i - j) << endl;
}
}
}
cout << "-1 -1 -1" << endl;
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:49: error: expected ')' before '{' token
   12 | if(y == 10000 * i + 5000 * j + 1000 * (n - i -j)
      |   ~                                             ^
      |                                                 )
   13 | {
      | ~                                                
a.cc:16:1: error: expected primary-expression before '}' token
   16 | }
      | ^
Language: C++

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

#define max(x, y)	(((x) > (y))? (x) : (y))
#define abs(x)		(((x) < 0)? (-1*(x)) : (x))

using namespace std;

int N,Y, a=-1,b=-1,c=-1;

int main() {
	int i,j;
	
	cin >> N >> Y;
	
	for ( i = 0; i <= 2000; i++ ) {
		for ( j = 0; j <= N - i ) {
			if ( (10000*i + 5000*j + 1000*(N-i-j) ) == Y) {
				a=i;b=j;c=N-i-j;
			}
		}
	}
	
	cout << a << " " << b << " " << c << endl;

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:19:40: error: expected ';' before ')' token
   19 |                 for ( j = 0; j <= N - i ) {
      |                                        ^~
      |                                        ;
Language: C++

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

#define max(x, y)	(((x) > (y))? (x) : (y))
#define abs(x)		(((x) < 0)? (-1*(x)) : (x))

using namespace std;

int N,Y, a=-1,b=-1,c=-1;

int main() {
	int i,j;
	cin >> N >> Y;
	
	for ( i = 0; i <= 2000; i++ ) {
		for ( j = 0; j < N - i ) {
			if ( (10000*i + 5000*j + 1000*(N-i-j) ) == Y)
			a=i;b=j;c=z;
		}
	}
	
	cout << a << " " << b << " " << c << endl;

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:39: error: expected ';' before ')' token
   18 |                 for ( j = 0; j < N - i ) {
      |                                       ^~
      |                                       ;
a.cc:20:35: error: 'z' was not declared in this scope
   20 |                         a=i;b=j;c=z;
      |                                   ^
Language: C++

N, Y = map(int, input().split())
 
a = 0
for x in range(N+1): 
    for y in range(N-x+1):
        if (10000*x + 5000*y + 1000*(N-x-y)) == Y:
            print(str(x)+" "+str(y)+" "+str(N-x-y))
            a = 1
            break
    if a == 1:
        break
 
if a != 1:
    print("-1 -1 -1")

Compiler output:
a.cc:1:1: error: 'N' does not name a type
    1 | N, Y = map(int, input().split())
      | ^
Language: C++

#include<iostream>
using namespace std;
int N,Y  ;
int main()
{
cin>>N>>Y;
for(int i=N;i>=0;i--)
for(int j=i;j>=;j--)
{
int x=Y-10000*i-5000*j;
if(x>=0 and x%1000==0 and i+j+x/1000==N)
{
cout<<i<<" "<<j<<" "<<x/1000;
system ("pause");
return 0;
}
}
cout<<"-1 -1 -1";
system ("pause");
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:16: error: expected primary-expression before ';' token
    8 | for(int j=i;j>=;j--)
      |                ^
Language: C++

#include <iostream>
using namespace std;

int main()
{
	int n,y,i,j,k;
	cin>>n>>y;
	
	for(i=0;i<=y/10000;i++){
		for(j=0;j<=y/5000;j++){
			s=n-i-j;
			if(k>=0&&i*10000+j*5000+k*1000==y){
				cout<<i<<" "<<j<<" "<<k<<endl;
				return 0;
			}
		}
	}
	cout<<"-1 -1 -1"<<endl;
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:25: error: 's' was not declared in this scope
   11 |                         s=n-i-j;
      |                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main()
{
	int x, y, z, N, Y;
	cin >> N >> y;
	for(int x=0;x<=Y/10000;x++)
	{
		for(int y=0;y<=Y/5000;y++)
		{
			z=N-x-y;
			if(z>=0&&z*2000+y*5000+x*10000==YA)
			{
				cout << x<<' '<< y<<' ' << z<<endl;
				return 0; 
			}
		}
	}
	cout <<"-1 -1 -1"<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:57: error: 'YA' was not declared in this scope; did you mean 'Y'?
   12 |                         if(z>=0&&z*2000+y*5000+x*10000==YA)
      |                                                         ^~
      |                                                         Y
Language: C++

#include <iostream>
using namespace std;
int main(void){
    int N,Y;
    cin >> N >> Y;
    for(int a=0;a<N+1;a++){
        for(int b=0;b<N+1-a;b++){
            int c=N-a-b;
            if(10000*a+5000*b+1000*c==Y)
            cout << a << " " << b << " " << c << endl;
            return;
        }
    }
    cout << "-1 -1 -1" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:13: error: return-statement with no value, in function returning 'int' [-fpermissive]
   11 |             return;
      |             ^~~~~~
Language: C++

#include <iostream>
using namespace std;
int main(void){
    int N,Y;
    cin >> N >> Y;
    for(int a=0;a<N+1;a++){
        for(int b=0;b<N+1-a;b++){
            int c=N-a-b
            if(10000*a+5000*b+1000*c==Y)
            cout << a << " " << b << " " << c << endl;
            return;
        }
    }
    cout << "-1 -1 -1" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:13: error: expected ',' or ';' before 'if'
    9 |             if(10000*a+5000*b+1000*c==Y)
      |             ^~
a.cc:11:13: error: return-statement with no value, in function returning 'int' [-fpermissive]
   11 |             return;
      |             ^~~~~~
Language: C++

#include <iostream>
using namespace std;
int main(void){
    int N,Y;
    cin >> N >> Y;
    for(int a=0;a<N+1;a++){
        for(int b=0;b<N+1-a;b++){
            c=N-a-b
            if(10000*a+5000*b+1000*c==Y)
            cout << a << " " << b << " " << c << endl;
            return;
        }
    }
    cout << "-1 -1 -1" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:13: error: 'c' was not declared in this scope
    8 |             c=N-a-b
      |             ^
a.cc:11:13: error: return-statement with no value, in function returning 'int' [-fpermissive]
   11 |             return;
      |             ^~~~~~
Language: C++

#include<iostream>
#include<algorithm>
using namespace std;
int main(){
    int N,Y;
    cin>>N>>Y;int z;
    for(int i=0;i<Y/1000;i++){
        for(int j=0;j<Y/5000)
    }
    cout<<"-1 -1 -1"<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:29: error: expected ';' before ')' token
    8 |         for(int j=0;j<Y/5000)
      |                             ^
      |                             ;
a.cc:9:5: error: expected primary-expression before '}' token
    9 |     }
      |     ^
Language: Java

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner scanner = new Scanner(System.in);
		int N = scanner.nextInt();
		int Y = scanner.nextInt();
		int man, ochun, chun;
		man = Y/10000;
		ochun= (Y%10000)/5000;
		chun= ((Y%10000)%5000)/1000;
		if(N>=(man+ochun+chun)) {
			System.out.println(man + " "+ ochun+ " "+ chun);
		} else {
			System.out.println("-1 -1 -1");
		}
		
		scanner.close();
		
		

	}

}

Compiler output:
Main.java:5: error: cannot find symbol
		Scanner scanner = new Scanner(System.in);
		^
  symbol:   class Scanner
  location: class Main
Main.java:5: error: cannot find symbol
		Scanner scanner = new Scanner(System.in);
		                      ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main()
{
	int n,m,i,j,k,u,l1,l2,l3;
	scanf("%d%d",&n,&m)； 
	l1=min(m/1000,n);
	l2=min(m/5000,n);
	l3=min(m/10000,n);
	for(i=0;i<=l1;i++)
	{
		for(j=0;j<=l2;j++)
		{
			for(k=0;k<=l3;k++)
			{
				if(i+j+k==n&&i*1000+j*5000+k*10000==m)
				{
					printf("%d %d %d",k,j,i);
					return 0;
				}
			}
		}
	}
	printf("-1 -1 -1");
	return 0;
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:6:28: error: expected ';' before '\U0000ff1b'
    6 |         scanf("%d%d",&n,&m)；
      |                            ^~
      |                            ;
Language: C++

#include<iostream>
using namespace std;
int main(){
int N,Y;
cin>>N>>Y;
for(int x=0;x<=n;x++)
for(int y=0;y<n-x;y++){
int z=N-x-y;
if(x*10000+y*5000+z*1000==Y){
cout<<x<<' '<<y<<' '<<z;
return 0;
}
}
cout<<"-1 -1 -1";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:16: error: 'n' was not declared in this scope
    6 | for(int x=0;x<=n;x++)
      |                ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main()
{
	int N, Y;
	cin >> N >>Y;
	int x, y, z;
	for(x=0;x<=Y/10000;x++)
	{
		for(y=0;y<=Y/5000;y++)
		{
			z=n-x-y;
			if(x>=0&&x*10000+y*5000+z*1000==Y)
			{
				cout << x << y << z <<endl;
				return 0;
			}
		}
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:27: error: 'n' was not declared in this scope
   12 |                         z=n-x-y;
      |                           ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main()
{
	int N, Y;
	cin >> N >>Y;
	int x, y, z;
	for(x=0;x<=Y/10000;x++)
	{
		for(y=0;y<=Y/5000;y++)
		{
			x=n-x-y;
			if(x>=0&&x*10000+y*5000+z*1000==Y)
			{
				cout << x << y << z <<endl;
				return 0;
			}
		}
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:27: error: 'n' was not declared in this scope
   12 |                         x=n-x-y;
      |                           ^