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

#include <cmath>
#include <iostream>
#include <vector>

int main() {
  int M, K;
  std::cin >> M >> K;

  int max = std::pow(2, M);
  std::vector<int> result(max * 2);
  std::vector<bool> used(max + 1);

  if (max <= K) {
    std::cout << -1 << std::endl;
    return 0;
  }

  if (M == 0) {
    if (K == 1) {
      std::cout << -1 << std::endl;
      return 0;
    } else {
      result[0] = 0;
      result[1] = 0;
    }
  } else if (M == 1) {
    if (K == 1) {
      std::cout << -1 << std::endl;
      return 0;
    } else {
      result[0] = 0;
      result[1] = 0;
      result[2] = 1;
      result[3] = 1;
    }
  } else {
    // 最初と真ん中らへんにKを配置する
    result[0] = result[max] = K;
    used[K] = true;

    // Kを構成要素をビットシフトで作る
    int i = 1;
    for (int n = 0; K != 0; ++n, K = K >> 1) {
      if ((K & 0x01) == 0x01) {
        int val = 1 << n;
        result[i] = result[result.size() - i] = val;
        used[val] = true;
        ++i;
      }
    }

    int last_val = 0;
    int val = 1;
    for (int end = max - 1; i < end; ++i) {
      while (used[val]) {
        ++val;
      }
      used[val] = true;
      result[i] = result[result.size() - i] = val;
      last_val ^= val;
    }

    result[max - 1] = result[max + 1] = last_val;
    // if (used[last_val]) {
    // result[max - 1] = result[max + 1] = last_val;
    // int change = result[max + 2];
    // result[max - 2] = result[max + 2] = change;
  }
  for (auto r : result) {
    std::cout << r << " ";
  }
  std::co

Compiler output:
a.cc: In function 'int main()':
a.cc:72:8: error: 'co' is not a member of 'std'; did you mean 'cos'?
   72 |   std::co
      |        ^~
      |        cos
a.cc:72:10: error: expected '}' at end of input
   72 |   std::co
      |          ^
a.cc:5:12: note: to match this '{'
    5 | int main() {
      |            ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int m,k;
int main()
{
	cin>>m>>k;
	if(m==1)
	{
		if(k==0)
		  cout<<"0 0 1 1"<<endl;
		else 
		  cout<<-1<<endl;
	}
	else 
	  if(k>=1<<m)
	  {
	    cout<<-1;
	    return 0;
	  }
	else
	{
		for(int i=0;i<1<<m;i++)
		  if(i!=k)
		    cout<<i<<" ";
		cout<<k<<" ";
		for(i=1<<m;i-1;i--)
		  if(i!=k)
		    cout<<i<<" ";
		cout<<k<<endl;
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:26:21: error: 'i' was not declared in this scope
   26 |                 for(i=1<<m;i-1;i--)
      |                     ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int m,k;
int main()
{
	cin>>m>>k;
	if(m==1)
	{
		if(k==0)
		  cout<<"0 0 1 1"<<endl;
		else 
		  cout<<-1<<endl;
	}
	else 
	  if(k>=1<<m)
	  {
	    cout<<-1;
	    return 0;
	  }
	else
	{
		for(i=0;i<1<<m;i++)
		  if(i!=k)
		    cout<<i<<" ";
		cout<<k<<" ";
		for(i=1<<m;i-1;i--)
		  if(i!=k)
		    cout<<i<<" ";
		cout<<k<<endl;
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:21: error: 'i' was not declared in this scope
   22 |                 for(i=0;i<1<<m;i++)
      |                     ^
a.cc:26:21: error: 'i' was not declared in this scope
   26 |                 for(i=1<<m;i-1;i--)
      |                     ^
Language: C++

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

int main(){
  int M,K;
  cin >> M >> K;
  if(K >= pow(2,M)){
    cout << -1 << endl;
    return 0;
  }
  if(M == 0){
    cout << "0 0" << endl;
    return 0;
  }
  if(K == 0){
    for(int i = 0;i < pow(2,M);i++)cout << i << " ";
    for(int i = pow(2,M)-1;i >= 1;i--)cout << i << " ";
    cout << 0 << endl;
    return 0;
  }
  if(M == 1){
    if(K == 0)cout << "0 0 1 1" << endl;
    else cout << -1 << endl;
    return;
  }
  for(int i = 0;i < pow(2,M);i++){
    if(i == K)continue;
    cout << i << " ";
  }
  cout << K << " ";
  for(int i = pow(2,M)-1;i >= 0;i--){
    if(i == K)continue;
    cout << i << " ";
  }
  cout << K << endl;
  return 0;
}

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

#include <bits/stdc++.h>
using namespace std;
#define REP(i,N) for(i=0;i<N;i++)
#define MAX_I INT_MAX //1e9
#define MIN_I INT_MIN //-1e9
#define MAX_UI UINT_MAX //1e9
#define MAX_LL LLONG_MAX //1e18
#define MIN_LL LLONG_MIN //-1e18
#define MAX_ULL ULLONG_MAX //1e19
  typedef long long ll;
  typedef pair<int,int> PII;
  typedef pair<char,char> PCC;
  typedef pair<ll,ll> PLL;
  typedef pair<char,int> PCI;
  typedef pair<int,char> PIC;
  typedef pair<ll,int> PLI;
  typedef pair<int,ll> PIL;
  typedef pair<ll,char> PLC;
  typedef pair<char,ll> PCL;

int main(void){
  int M;cin >> M;
  ll K; cin >> K;
  ll M_2 = 1 << M;
  if( M_2=<K || ( M==1 && K==1) ){
    cout << -1 << endl;
    return 0;
  }
  int i;
  if(K!=0) cout << K << " ";
  REP(i,M_2){
    if(K!=0 && i==K)continue;
    cout << i << " ";
  }
  if(K!=0) cout << K << " ";
  REP(i,M_2){
    if(K!=0 && M_2-i-1==K)continue;
    cout << M_2-i-1 << " ";
  }
  cout << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:11: error: expected primary-expression before '<' token
   25 |   if( M_2=<K || ( M==1 && K==1) ){
      |           ^
Language: C++

#include <bits/stdc++.h>
#define REP(i, n) for(ll i = 0; i < (ll)n; i++)
#define FOR(i, a, b) for(ll i = (a); i < (ll)b; i++)
#define ALL(obj) (obj).begin(), (obj).end()
#define INF 1000000000000000
using namespace std;
typedef long long ll;
typedef double db;
typedef string str;
typedef pair<ll, ll> p;
constexpr int MOD = 1000000007;
template <class T> inline bool chmin(T &a, T b) {
    if(a > b) {
        a = b;
        return true;
    }
    return false;
}
template <class T> inline bool chmax(T &a, T b) {
    if(a < b) {
        a = b;
        return true;
    }
    return false;
}

void print(const std::vector<int> &v) {
    std::for_each(v.begin(), v.end(), [](int x) { std::cout << x << " "; });
    std::cout << std::endl;
}
// http://drken1215.hatenablog.com/entry/2019/05/19/230600

void solve(int M, int K) {
    if(M == 0) {
        if(K != 0) {
            cout << -1 << endl;
        } else {
            cout << "0 0" << endl;
        }
        return;
    } else if(M == 1) {
        if(K != 0) {
            cout << -1 << endl;
        } else {
            cout << "0 0 1 1" << endl;
        }
    }
    if(K >= (1 << M)) {
        cout << -1 << endl;
    }
    if(K == 0) {
        for(int bit = 0; bit < (1 << M); bit++) {
            cout << bit << " ";
        }
        for(int bit = (1 << M) - 1; bit >= 0; bit--) {
            cout << bit << " ";
        }
        cout << endl;
        return;
    }
    using pint = pair<int, int>;
    vector<pint> v;
    for(int bit = 0; bit < (1 << M); bit++) {
        v.push_back(pint(min(bit, bit ^ K), max(bit, bit ^ K))); // bit xor
    } //小さいのと大きいののペア
    sort(v.begin(), v.end());
    v.erase(unique(v.begin(), v.end()), v.end()));//ほんとに重複有るのかなって思うけど
    for(int i = 0; i < v.size(); i += 2) {
        cout << v[i].first << " " << v[i].second << " " << v[i + 1].first << " "
             << v[i + 1].second << " " << v[i].second << " " << v[i].first
             << " " << v[i + 1].second << " " << v[i + 1].first << " ";
    }
    cout << endl;
}

int main() {
    int M, K;
    cin >> M >> K;
    solve(M, K);
}

Compiler output:
a.cc: In function 'void solve(int, int)':
a.cc:67:49: error: expected ';' before ')' token
   67 |     v.erase(unique(v.begin(), v.end()), v.end()));//ほんとに重複有るのかなって思うけど
      |                                                 ^
      |                                                 ;
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
#define INIT() ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define Rep(i,n) for (int i = 0; i < (n); ++i)
#define For(i,s,t) for (int i = (s); i <= (t); ++i)
#define rFor(i,t,s) for (int i = (t); i >= (s); --i)
#define ForLL(i, s, t) for (LL i = LL(s); i <= LL(t); ++i)
#define rForLL(i, t, s) for (LL i = LL(t); i >= LL(s); --i)
#define foreach(i,c) for (__typeof(c.begin()) i = c.begin(); i != c.end(); ++i)
#define rforeach(i,c) for (__typeof(c.rbegin()) i = c.rbegin(); i != c.rend(); ++i)
 
#define pr(x) cout << #x << " = " << x << "  "
#define prln(x) cout << #x << " = " << x << endl
 
#define LOWBIT(x) ((x)&(-x))
 
#define ALL(x) x.begin(),x.end()
#define INS(x) inserter(x,x.begin())
 
#define ms0(a) memset(a,0,sizeof(a))
#define msI(a) memset(a,inf,sizeof(a))
#define msM(a) memset(a,-1,sizeof(a))

#define MP make_pair
#define PB push_back
#define ft first
#define sd second
 
template<typename T1, typename T2>
istream &operator>>(istream &in, pair<T1, T2> &p) {
    in >> p.first >> p.second;
    return in;
}
 
template<typename T>
istream &operator>>(istream &in, vector<T> &v) {
    for (auto &x: v)
        in >> x;
    return in;
}
 
template<typename T1, typename T2>
ostream &operator<<(ostream &out, const std::pair<T1, T2> &p) {
    out << "[" << p.first << ", " << p.second << "]" << "\n";
    return out;
}

inline int gc(){
	static const int BUF = 1e7;
	static char buf[BUF], *bg = buf + BUF, *ed = bg;
	
	if(bg == ed) fread(bg = buf, 1, BUF, stdin);
	return *bg++;
} 

inline int ri(){
	int x = 0, f = 1, c = gc();
	for(; c<48||c>57; f = c=='-'?-1:f, c=gc());
	for(; c>47&&c<58; x = x*10 + c - 48, c=gc());
	return x*f;
}
 
typedef long long LL;
typedef unsigned long long uLL;
typedef pair< double, double > PDD;
typedef pair< int, int > PII;
typedef pair< string, int > PSI;
typedef set< int > SI;
typedef vector< int > VI;
typedef map< int, int > MII;
typedef pair< LL, LL > PLL;
typedef vector< LL > VL;
typedef vector< VL > VVL;
const double EPS = 1e-10;
const LL inf = 0x7fffffff;
const LL infLL = 0x7fffffffffffffffLL;
const LL mod = 1e9 + 7;
const int maxN = 3e5 + 7;
const LL ONE = 1;
const LL evenBits = 0xaaaaaaaaaaaaaaaa;
const LL oddBits = 0x5555555555555555;

// 返回低 x 位全 1 
inline LL allOne(LL x) {
    return (ONE << x) - 1;
}

LL N, M, K;
int oneCounts;

int main(){
	INIT(); 
	cin >> M >> K;
	N = (1 << M) - 1;
	if(N == 1) {
		if()
	}
	if(K > N) cout << -1 << endl;
	else if(N == 1) {
		if(K == 1) cout << -1 << endl;
		else cout << 0 << 0 << 1 << 1 << endl;
	}
	else {
		For(i, 0, N) if(i != K) cout << i << " ";
		cout << K << " ";
		rFor(i, N, 0) if(i != K) cout << i << " ";
		cout << K << " ";
		cout << endl;
	}
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:97:20: error: expected primary-expression before ')' token
   97 |                 if()
      |                    ^
a.cc:98:9: error: expected primary-expression before '}' token
   98 |         }
      |         ^
Language: C++

#include<bits/stdc++.h>
#define ll long long
#define ld long double
#define mod 1000000007
#define fi first
#define se second
#define pb push_back
#define IOS ios_base::sync_with_stdio(false);cout.tie(NULL);cin.tie(NULL);

using namespace std;

int main()
{
    IOS;
    ll m,k;
    cin>>m>>k;
    if(k>=(1<<m )|| (k==1 && m==1))
    {
        cout<<-1<<endl;
        return 0;
    }
    if(k==0)
    {
        for(ll i=0;i<(1<<m;)i++)
        {
            cout<<i<<" "<<i<<" ";
        }
        cout<<endl;
        return 0;
    }
    for(ll i=1;i<1<<m;i++)
    {
        if(i!=k) cout<<i<<" ";
    }
    cout<<k<<" ";
    for(ll i=1<<m-1;i>=1;i--)
    {
        cout<<i<<" ";
    }
    cout<<0<<" "<<k<<" "<<0<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:27: error: expected ')' before ';' token
   24 |         for(ll i=0;i<(1<<m;)i++)
      |                      ~    ^
      |                           )
a.cc:24:32: error: expected ';' before ')' token
   24 |         for(ll i=0;i<(1<<m;)i++)
      |                                ^
      |                                ;
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;
typedef tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update> ordered_set;
//find_by_order(k) - return iterator k-th largest element (k from 0)
//order_of_key(x) - return number of items that smaller than x
typedef long long LL;

int main() {
	int M, K;
	cin >> M >> K;
	int bil = 1;
	for (int i = 0; i < M - 1; i++) {
		bil *= 2;
	}
	if (K == 0) {
		for (int i = 0; i <= bil; i++) {
			if (i > 0) printf(" ");
			printf("%d", i);
		}
		for (int i = bil; i >= 0; i--) {
			printf(" %d", i);
		}
		printf("\n");
	} else {
		if (M % 4 == 3) {
			if (K >= 2 * M) printf("-1\n");
			else {
				int tmp = bil;
				vector<int> v;
				while (K > 0) {
					if (K >= tmp) {
						v.push_back(tmp);
						K -= tmp;
					}
					tmp /= 2;
				}
				int l = v[0], r = 0;
				int l1 = v.size();
				for (int i = 1; i < l1; i++) {
					r += v[i];
				}	
				bool awal = 1;
				for (int i = 0; i <= bil; i++) {
					if (i != l && i != r) {
						if (!awal) printf(" ");
						awal = 0;
						printf("%d", i);
					}
				}
				printf(" %d %d", l, r);
				for (int i = bil; i >= 0; i--) {
					if (i != l && i != r) printf(" %d", i);
				}
				printf(" %d %d\n", l, return);
			}
		} else printf("-1\n");
	} 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:58:55: error: expected primary-expression before 'return'
   58 |                                 printf(" %d %d\n", l, return);
      |                                                       ^~~~~~
Language: C++

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

//repetition
#define FOR(i,a,b) for(ll i=(a);i<(b);++i)
#define rep(i, n) for(ll i = 0; i < (ll)(n); i++)

//container util
#define all(x) (x).begin(),(x).end()

//typedef
typedef long long ll;
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<ll> VLL;
typedef vector<VLL> VVLL;
typedef vector<string> VS;
typedef pair<int, int> PII;
typedef pair<ll, ll> PLL;

//const value
//const ll MOD = 1e9 + 7;
//const int dx[] = {0,1,0,-1};//{0,0,1,1,1,-1,-1,-1};
//const int dy[] = {1,0,-1,0};//{1,-1,0,1,-1,0,1,-1};

//conversion
inline int toInt(string s) {int v; istringstream sin(s);sin>>v;return v;}
inline ll toLL(string s) {ll v; istringstream sin(s);sin>>v;return v;}
template<class T> inline string toString(T x) {ostringstream sout;sout<<x;return sout.str();}


int main(){
  ios::sync_with_stdio(false);
  cin.tie(0);
  ll m,K;
  cin >> m >> K;
  if (K >= (1<<m)) {
        cout << -1 << endl;
        return 0;
  }
  if(K==0){
    rep(i,(1LL<<m)){
      if(((1LL<<m) - 1) != i) cout << i << ' ' << i << ' ';
      else cout << i << ' ' << i << endl;
  }
  else if(m == 1 && k != 0){
    cout << -1 << endl;
    return 0;
  }
  }else{

    VLL ans;
    bool used[(1<<m)];
    memset(used,0,sizeof(used));
    vector<PII> v;
    rep(i,(1<<m)){
      if(used[i]) continue;
      v.push_back(make_pair( min(i,K^i) , max(i,K^i) ));
      used[i] = true;
      used[K^i] = true;
    }
    for(ll i = 0; i < v.size(); i+=2){
      cout << v[i].first << ' ' << v[i].second << ' ' <<
              v[i+1].first << ' ' << v[i+1].second << ' ' <<
              v[i].second << ' ' << v[i].first << ' ' <<
              v[i+1].second << ' ' << v[i+1].first << ' ';
    }
    cout << endl;
  }


  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:46:3: error: expected '}' before 'else'
   46 |   else if(m == 1 && k != 0){
      |   ^~~~
a.cc:41:11: note: to match this '{'
   41 |   if(K==0){
      |           ^
a.cc:46:21: error: 'k' was not declared in this scope
   46 |   else if(m == 1 && k != 0){
      |                     ^
a.cc: At global scope:
a.cc:50:4: error: expected unqualified-id before 'else'
   50 |   }else{
      |    ^~~~
a.cc:72:3: error: expected unqualified-id before 'return'
   72 |   return 0;
      |   ^~~~~~
a.cc:73:1: error: expected declaration before '}' token
   73 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> pii;
#define pb push_back
#define mp make_pair
#define rep(i,n) for(int i=0;i<(n);++i)
const int mod=1000000007;
const int mod1=998244353;

int main(){
	cin.tie(0);
	ios::sync_with_stdio(false);
	int n,k;cin >> n >> k;
	int t=(1<<n);
	if(k==0){
		rep(i,t){
			if(i==t-1) cout << i << " " << i << endl;
			else cout << i << " " << i << " ";
		}
	}
	else if(k>=t || m==1) cout << -1 << endl;
	else{
		vector<int> a((t<<1));
		a.at(0)=0;
		a.at(1)=k;
		a.at(2)=0;
		int i=3,m=1;
		while(m<t){
			if(m==k){
				m++;
				if(m==t) break;
			}
			a.at(i)=m;
			m++;
			i++;
		}
		m--;
		a.at(i)=k;
		i++;
		while(m>0){
			if(m==k){
				m--;
				if(m==0) break;
			}
			a.at(i)=m;
			m--;
			i++;
		}
		rep(j,(t<<1)){
			if(j==(t<<1)-1) cout << a.at(j) << endl;
			else cout << a.at(j) << " ";
		}
	}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:25: error: 'm' was not declared in this scope
   22 |         else if(k>=t || m==1) cout << -1 << endl;
      |                         ^
a.cc:28:25: error: redeclaration of 'int m'
   28 |                 int i=3,m=1;
      |                         ^
a.cc:22:25: note: '<typeprefixerror>m' previously declared here
   22 |         else if(k>=t || m==1) cout << -1 << endl;
      |                         ^
Language: C++

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

int main(){
    ios::sync_with_stdio(false);
    cin.tie(0);

    int M, K;
    cin >> M >> K;

    long long n = 1;
    for (int i=0; i<M; ++i) n *= 2;

    if (n < K) {
        cout << -1 << endl;
        return;
    }

    if (K != (n * 2) ^ K) {
        cout << -1 << endl;
        return ;
    }

    vector<int> v;
    v.push_back(K);
    for (int i=1; i<=n; ++i) {
        if (i == K) continue;
        v.push_back(i);
    }
    v.push_back(K);
    for (int i=n; i>=1; --i) {
        if (i == K) continue;
        v.push_back(i);
    }

    for (int i=0; i<v.size(); ++i) {
        cout << (i==0 ? "" : " ") << v[i];
    }
    cout << endl;

    return 0;
}

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

#include <algorithm>
#include <bitset>
#include <cassert>
#include <cctype>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <deque>
#include <fstream>
#include <functional>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <vector>
using namespace std;
using ll = long long;
#define fst first
#define snd second

/* clang-format off */
template <class T, size_t D> struct _vec { using type = vector<typename _vec<T, D - 1>::type>; };
template <class T> struct _vec<T, 0> { using type = T; };
template <class T, size_t D> using vec = typename _vec<T, D>::type;
template <class T> vector<T> make_v(size_t size, const T& init) { return vector<T>(size, init); }
template <class... Ts> auto make_v(size_t size, Ts... rest) { return vector<decltype(make_v(rest...))>(size, make_v(rest...)); }
template <class T> inline void chmin(T &a, const T& b) { if (b < a) a = b; }
template <class T> inline void chmax(T &a, const T& b) { if (b > a) a = b; }
/* clang-format on */

int main() {
#ifdef DEBUG
  ifstream ifs("in.txt");
  cin.rdbuf(ifs.rdbuf());
#endif
  int M;
  ll K;
  while (cin >> M >> K) {
    int N = 1 << M;
    if (K >= N) {
      cout << -1 << endl;
      continue;
    }
    vector<int> res;
    res.push_back(K);
    vector<int> used(1 << M, 0);
    used[K] = 1;
    vector<int> tmp;
    for (int i = 0; i < 40; i++) {
      ll v = 1ll << i;
      if (used[v]) continue;
      if ((K >> i) & 1) {
        tmp.push_back(v);
        res.push_back(v);
        used[v] = 1;
      }
    }
    res.push_back(K);
    for (int i = (int)tmp.size() - 1; i >= 0; i--) {
      res.push_back(tmp[i]);
    }
    vector<int> res2;
    for (int i = 0; i < (1 << M); i++)
      if (!used[i]) res2.push_back(i);
    for (int x : res) res2.push_back(x);
    for (int i = (1 << M) - 1; i >= 0; i--)
      if (!used[i]) res2.pop_back(i);
    for (int x : res2) cout << x << " ";
    cout << endl;
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:69:34: error: no matching function for call to 'std::vector<int>::pop_back(int&)'
   69 |       if (!used[i]) res2.pop_back(i);
      |                     ~~~~~~~~~~~~~^~~
In file included from /usr/include/c++/14/vector:66,
                 from /usr/include/c++/14/functional:64,
                 from a.cc:10:
/usr/include/c++/14/bits/stl_vector.h:1324:7: note: candidate: 'void std::vector<_Tp, _Alloc>::pop_back() [with _Tp = int; _Alloc = std::allocator<int>]'
 1324 |       pop_back() _GLIBCXX_NOEXCEPT
      |       ^~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1324:7: note:   candidate expects 0 arguments, 1 provided
Language: C++

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

#define Online 1
// #define multitest 1
#define Debug 1
typedef long long ll;
typedef long double ld;
#define f first
#define s second
#define pb push_back
#define mp make_pair
const long long mod = 1000000007;
const long long High = 1e16;
void ControlIO();
void TimerStart();
void TimerStop();
#ifdef Debug
#define db(...) ZZ(#__VA_ARGS__, __VA_ARGS__)
template <typename Arg1>
void ZZ(const char *name, Arg1 &&arg1)
{
    std::cerr << name << " = " << arg1 << endl;
}
template <typename Arg1, typename... Args>
void ZZ(const char *names, Arg1 &&arg1, Args &&... args)
{
    const char *comma = strchr(names + 1, ',');
    std::cerr.write(names, comma - names) << " = " << arg1;
    ZZ(comma, args...);
}
#else
#define db(...)
#endif

void solve()
{
    int m, k;
    cin >> m >> k;
    vector<int> V;
    int n = (int)pow(2, m + 1);
    for (int i = 0; i < n; ++i)
        V.pb(i / 2);
    if(i==m && k==1)
    {
        cout << -1;
        return;
    }
    if (k == 0)
    {
        for (int i = 0; i < n; ++i)
            cout << V[i] << ' ';
        return;
    }
    else if (k <= V[n - 1])
    {
        set<int> S;
        for (int i = 0; i < n; ++i)
        {
            if (V[i] == k)
                continue;
            S.insert(V[i]);
        }
        vector<int> X;
        for(auto it=S.begin();it!=S.end();++it)
        {
            X.pb(*it);
            cout << *it << ' ';
        }
        cout << k << ' ';
        reverse(X.begin(),X.end());
        for(auto x : X)
            cout << x << ' ' ;
        cout << k ;
    }
    else
        cout << -1;
}

int main()
{
    ControlIO();
    int t = 1;
#ifdef multitest
    cin >> t;
#endif
    TimerStart();
    while (t--)
        solve();
    TimerStop();
    return 0;
}

void ControlIO()
{
    ios_base::sync_with_stdio(0);
    cin.tie(0);
#ifndef Online
    freopen("input.txt", "r", stdin);
    freopen("output.txt", "w", stdout);
#endif
}

auto TimeStart = chrono::steady_clock::now();
auto TimeEnd = chrono::steady_clock::now();

void TimerStart()
{
#ifndef Online
    TimeStart = chrono::steady_clock::now();
#endif
}

void TimerStop()
{
#ifndef Online
    TimeEnd = chrono::steady_clock::now();
    auto ElapsedTime = TimeEnd - TimeStart;
    cout << "\n\nTime elapsed: " << chrono::duration<double>(ElapsedTime).count() << " seconds.\n";
#endif
}

Compiler output:
a.cc: In function 'void solve()':
a.cc:45:8: error: 'i' was not declared in this scope
   45 |     if(i==m && k==1)
      |        ^
Language: C++

#include <iostream>

int main() {
  int M, K; std::cin >> M >> K;
  if (K != 0) std::cout << -1 << std::endl;
  else assert(false);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:8: error: 'assert' was not declared in this scope
    6 |   else assert(false);
      |        ^~~~~~
a.cc:2:1: note: 'assert' is defined in header '<cassert>'; this is probably fixable by adding '#include <cassert>'
    1 | #include <iostream>
  +++ |+#include <cassert>
    2 |
Language: C++


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

typedef long long int ll;
typedef pair<ll, ll> pll;

#define FOR(i, n, m) for (ll(i) = (m); (i) < (n); ++(i))
#define REP(i, n) FOR(i, n, 0)
#define OF64 std::setprecision(10)

const ll MOD = 1000000007;
const ll INF = (ll)1e15;

bool U[300000];

int main()
{
    ll M, K;
    cin >> M >> K;

    ccout << -1 << endl;
    return 0;
    ll t = pow(2, M) - 1;
    ll xr = 0;
    REP(i, t + 1)
    {
        xr ^= i;
    }

    if (K == 0)
    {
        REP(i, pow(2, M + 1))
        {
            cout << i / 2 << " ";
        }
        cout << endl;
    }

    memset(U, 0, sizeof(U));
    if (xr xor K == K)
    {
        vector<ll> n;
        REP(i, 32)
        {
            if (((K >> i) & 1) == 1)
            {
                ll m = 1LL << i;
                if (m > t)
                {
                    cout << -1 << endl;
                    return 0;
                }
                n.push_back(m);
                U[m] = true;
            }
        }

        vector<ll> ans;
        REP(i, t + 1)
        {
            if (U[i])
                continue;
            ans.push_back(i);
        }
        REP(i, n.size())
        {
            ans.push_back(n[i]);
        }
        for (ll i = t; i >= 0; --i)
        {
            if (U[i])
                continue;
            ans.push_back(i);
        }
        for (int i = n.size() - 1; i >= 0; --i)
        {
            ans.push_back(n[i]);
        }

        REP(i, ans.size())
        {
            cout << ans[i] << " ";
        }
        cout << endl;
    }
    else
    {
        cout << -1 << endl;
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:22:5: error: 'ccout' was not declared in this scope
   22 |     ccout << -1 << endl;
      |     ^~~~~
Language: C++

m, k = gets.split.map(&:to_i)


if k != 0
  puts "-1"
else
  a = []

  (1 << m).times do |i|
    a << i
    a << i
  end

  puts a.join(' ')
end


Compiler output:
a.cc:1:1: error: 'm' does not name a type
    1 | m, k = gets.split.map(&:to_i)
      | ^
Language: C++

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

using namespace std;

int main() {
	int M, K; cin >> M >> K;
	if (K == 0) {
		int m = pow(2, M);
		for (int i = 0; i < m; i++) {
			cout << i << " " << i << " ";
		}
	}
	else[
		cout << "-1";
	]
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:20:17: warning: capture of variable 'std::cout' with non-automatic storage duration
   20 |                 cout << "-1";
      |                 ^~~~
In file included from a.cc:1:
/usr/include/c++/14/iostream:63:18: note: 'std::ostream std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:20:21: error: expected ',' before '<<' token
   20 |                 cout << "-1";
      |                     ^~~
      |                     ,
a.cc:20:22: error: expected identifier before '<<' token
   20 |                 cout << "-1";
      |                      ^~
a.cc:20:29: error: expected ']' before ';' token
   20 |                 cout << "-1";
      |                             ^
      |                             ]
a.cc: In lambda function:
a.cc:20:29: error: expected '{' before ';' token
a.cc: In function 'int main()':
a.cc:21:9: error: expected primary-expression before ']' token
   21 |         ]
      |         ^
Language: C++

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

#include <vector>
#include <set>
#include <map>
#include <iostream>
#include <utility>
#include <queue>
#include <algorithm>
#include <functional>
#include <string>
#include <bitset>

#define ll long long
#define fri(n) for(i=0;i<(n);i++)
#define frj(n) for(j=0;j<(n);i++)
#define min(p,q) ((p)<(q)?(p):(q))
#define max(p,q) ((p)>(q)?(p):(q))
#define INF 1000000000000000000//10^18
#define INFINT 2000000001//2*10^9+1
#define MOD 1000000007
#define MODANOTHER 998244353
#define PI acos(-1)

using namespace std;

struct edge{
	int to;
	int cost;
};

vector<edge> graph[100010];
int come[100010];
struct edge e;

int search(int x){
	int i;

	come[x]=1;

	for(i=0;i<graph[x].size();i++){
		e=graph[x][i];
		if(come[e.to]==-1){
			search(e.to);
		}
	}

	return 0;
}

int main(void)
{
	//変数の宣言
	int n,m;

	//よく使う変数
	int i,j,k,l;
	int flag=0;
	int ans=0;
	int count=0;
	int temp=0;
	int temp1=0;
	int temp2=0;
	int max=0;
	int min=INFINT;
	int len=0;
	int sum=0;
	int ok=0;
	int ng=0;
	char dummy;



	//データの読み込み


//	scanf("%d %d",&m,&n);
	scanf_s("%d %d",&m,&n);

//	scanf("%s",&s);
//	scanf_s("%s",&s,5);


/*	for(i=0;i<m;i++){
//		scanf("%d %d %d",&x,&y,&z);
		scanf_s("%d %d %d",&x,&y,&z);
	}

	for(i=1;i<=n;i++){
		come[i]=-1;
	}*/

	//	printf("nは%dです\n", n);
	//	printf("データの読み込み終了\n");
	//実際の処理

	temp=(1<<m);

	if(n==1 && m==1){
		printf("-1");
		return 0;
	}

	if(temp<=n){
		printf("-1");
		return 0;
	}

	for(i=0;i<temp;i++){
		if(i!=n){
			printf("%d ",i);
		}
	}
	printf("%d ",n);

	for(i=temp-1;i>=0;i--){
		if(i!=n){
			printf("%d ",i);
		}
	}
	printf("%d",n);


	//	printf("計算部分終了\n");

	//出力
	//printf("%d",ans);


	//	printf("結果の出力終了\n");

	return 0;
}



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

#include <stdio.h>

int main()
{
	int M, K;

	scanf("%d %d", &M, &K);

	if (K != 0)
	{
		int xor = 0;

		for (int i = 0; i < (1 << M); ++i)
		{
			if (i == K) continue;
			xor ^= i;
		}

		if (xor != K) printf("-1\n");
		else
		{
			printf("%d ", K);
			for (int i = 0; i < (1 << M); ++i)
			{
				if (i == K) continue;
				printf("%d ", i);
			}
			printf("%d ", K);
			for (int i = (1 << M) - 1; i >= 0; --i)
			{
				if (i == K) continue;
				printf("%d ", i);
			}
			printf("\n");
		}
	}
	else
	{
		for (int i = 0; i < (1 << M); ++i) printf("%d %d ", i, i);
		printf("\n");
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:21: error: expected unqualified-id before 'xor' token
   11 |                 int xor = 0;
      |                     ^~~
a.cc:16:25: error: expected primary-expression before 'xor' token
   16 |                         xor ^= i;
      |                         ^~~
a.cc:16:29: error: expected primary-expression before '^=' token
   16 |                         xor ^= i;
      |                             ^~
a.cc:19:21: error: expected primary-expression before 'xor' token
   19 |                 if (xor != K) printf("-1\n");
      |                     ^~~
a.cc:19:25: error: expected primary-expression before '!=' token
   19 |                 if (xor != K) printf("-1\n");
      |                         ^~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define _GLIBCXX_DEBUG
#define rep(i, from, to) for (int i = from; i < (to); ++i)
#define mp(x,y) make_pair(x,y)
#define all(x) (x).begin(),(x).end()
#define pb push_back
using ll = long long;
using vin=vector<int>;
using vll=vector<ll>;
using vst=vector<string>;
using P = pair<int, int>;
const int inf=1e9+7;
const ll INF=1e18;
template <typename T> void chmin(T &a, T b) { a = min(a, b); }
template <typename T> void chmax(T &a, T b) { a = max(a, b); }
template<class T> inline void Yes(T condition){ if(condition) cout << "Yes" << endl; else cout << "No" << endl; }
template<class T> inline void YES(T condition){ if(condition) cout << "YES" << endl; else cout << "NO" << endl; }
const int dx[4] = { 1, 0, -1, 0 };
const int dy[4] = { 0, 1, 0, -1 };


int main(){cout<<fixed<<setprecision(10);
		   int n,k;
           cin>>n>>K;
           cout<<n-k+1<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:20: error: 'K' was not declared in this scope
   25 |            cin>>n>>K;
      |                    ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
itn main(){
int n, k;
cin>>n>>k;
cout<<n - k + 1;
}

Compiler output:
a.cc:3:1: error: 'itn' does not name a type; did you mean 'int'?
    3 | itn main(){
      | ^~~
      | int
Language: C++

#include <iostream>
using namespace std;

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

  cout << n-k+1 << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:16: error: expected ';' before 'cout'
    6 |   cin >> n >> k
      |                ^
      |                ;
    7 | 
    8 |   cout << n-k+1 << endl;
      |   ~~~~
Language: C++

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

int main() {
  int n, k;
  cin >> n >>k;
  cout >> n-k+1;
  return 0;
}

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

#include<stdio.h>

int main() {
	int n, k;
	scanf_s("%d %d", &n, &k);
	printf("%d", n - k + 1);
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
    5 |         scanf_s("%d %d", &n, &k);
      |         ^~~~~~~
      |         scanf
Language: C++

#include<iostream>
using namespace std;
int main()
{
int n,k;
cin>>n>>k;
cout<<n-k+1<<endl;

Compiler output:
a.cc: In function 'int main()':
a.cc:7:19: error: expected '}' at end of input
    7 | cout<<n-k+1<<endl;
      |                   ^
a.cc:4:1: note: to match this '{'
    4 | {
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int n,k;
  cin>>n>>k;
  
  cout<<n-k+1;<<endl;
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:15: error: expected primary-expression before '<<' token
    7 |   cout<<n-k+1;<<endl;
      |               ^~
Language: C++

#include <bits/stdc++.h>

int main(int argc,char **argv){
	int n,k;
	std::cin>>n>>k;
	std::out<<n-k+1<<'\n';
	return 0;
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:6:14: error: 'out' is not a member of 'std'; did you mean 'oct'?
    6 |         std::out<<n-k+1<<'\n';
      |              ^~~
      |              oct
Language: C++

//Dragon_warrior7(IITK)
#pragma GCC optimize ("Ofast")
#pragma GCC target ("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#pragma GCC optimize ("-ffloat-store")
#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 umap unordered_map
#define uset unordered_set
#define ll long long
#define pb push_back
#define nl cout << '\n'
#define sor(x) sort(x.begin(), x.end())
#define rev(v) reverse(v.begin(), v.end())
#define lb(v, temp) lower_bound(v.begin(), v.end(), temp)
#define ub(v, temp) upper_bound(v.begin(), v.end(), temp)
#define fi first
#define se second
#define llmax 1000000000000000000
#define pll pair<ll, ll> 
#define ull unsigned ll
#define vll vector<ll> 
#define rub cout << "\n------------------------------------\n"
#define deb(x) cout<<#x<<' '<<'='<<' '<<x<<'\n'
#define fo(i,a,b) for(int i=a;i<b;i++)
//typedef  tree < int ,  null_type ,  greater<int> ,  rb_tree_tag ,  tree_order_statistics_node_update > oset;
void read(vector<ll> &v)
{
	for (int i = 0; i < v.size(); i++)
		cin >> v[i];
}
// const int mod=1e9+7;
// ll power(ll a,ll b) {ll res=1;a%=mod; assert(b>=0); for(;b;b>>=1){if(b&1)res=res*a%mod;a=a*a%mod;}return res;}
// ll modInverse(ll a){return power(a,mod-2);}
ll n,m,a,b,c,k,temp,x,y;
const int MAXN=100000+11;
void solveforthiscase(const int & test)
{//deb(test);
cin>>n;
cin>>k;
cout<<n-k+1





return ;
}
int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(NULL);
	cout.tie(NULL);
	int test=1;
// 	cin>>test;
    for(int i=1;i<=test;i++)
    {
        solveforthiscase(i);
    }
}

Compiler output:
a.cc: In function 'void solveforthiscase(const int&)':
a.cc:43:12: error: expected ';' before 'return'
   43 | cout<<n-k+1
      |            ^
      |            ;
......
   49 | return ;
      | ~~~~~~
Language: C++

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

int main(){
  int N, K;
  cin >> N >> K;
  cout << N-K+1 << endl;
}

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

#include<bits/stdc++.h>
using namespace std;
int main(){int n,k;cin>>n>>k;cout<<n-k+1;

Compiler output:
a.cc: In function 'int main()':
a.cc:3:42: error: expected '}' at end of input
    3 | int main(){int n,k;cin>>n>>k;cout<<n-k+1;
      |           ~                              ^
Language: C++

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

int main(){
	int n, k;
  cin >> n >> k;
  cout << n - k + 1;
  return 0;
}

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

#include<bits/stdc++.h>
using namespace std;
int n,k;

int main()
{
	cin>>n>>k;
	cout<<n-k+1<<endl;
	
	return 0;
}

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

#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
const int INF = 1000000007;

 
int main(){
  cin.tie(nullptr);
  ios::sync_with_stdio(false);

  int N;
  cin >> N;
  cout << N-K+1 << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:13: error: 'K' was not declared in this scope
   13 |   cout << N-K+1 << endl;
      |             ^
Language: C++

#include<cstdio>
#include<cstdlib>
#include<algorithm>
#include<iostream>
#include<queue>
#include<vector>
#include <bitset>
#include <cmath>
#include <limits>
#include <iostream>
#include<set>
#include<tuple>
using namespace std;
#define INF 11000000000
#define MAX 100000
#define MOD 1000000007
typedef long long ll;
typedef pair<int,int> P;
typedef pair<pair<int,int>,int> p;
typedef pair< pair<int,int>, int> p; 
#define bit(n,k) ((n>>k)&1) /*nのk bit目*/
#define rad_to_deg(rad) (((rad)/2/M_PI)*360)



int main(){
    calc_com();
    int N,K;
    cin>>N>>K;
    cout<<N-K+1<<endl;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:27:5: error: 'calc_com' was not declared in this scope
   27 |     calc_com();
      |     ^~~~~~~~
Language: C++

#include<cstdio>
#include<cstdlib>
#include<algorithm>
#include<iostream>
#include<queue>
#include<vector>
#include <bitset>
#include <cmath>
#include <limits>
#include <iostream>
#include<set>
#include<tuple>
using namespace std;
#define INF 11000000000
#define MAX 100000
#define MOD 1000000007
typedef long long ll;
typedef pair<int,int> P;
typedef pair<pair<int,int>,int> p;
typedef pair< pair<int,int>, int> p; 
#define bit(n,k) ((n>>k)&1) /*nのk bit目*/
#define rad_to_deg(rad) (((rad)/2/M_PI)*360)

//http://drken1215.hatenablog.com/entry/2018/06/08/210000
const int MAX_C=1000;
ll Com[MAX_C][MAX_C];

void calc_com(){
    memset(Com,0,sizeof(Com));
    Com[0][0]=1;
    for(int i=1;i<MAX_C;i++){
        Com[i][0]=1;
        for(int j=1;j<MAX_C;j++){
            Com[i][j]=(Com[i-1][j-1]+Com[i-1][j])%MOD;
        }
    }
}


int main(){
    calc_com();
    int N,K;
    cin>>N>>K;
    cou<<N-K+1<<endl;
}



Compiler output:
a.cc: In function 'void calc_com()':
a.cc:29:5: error: 'memset' was not declared in this scope
   29 |     memset(Com,0,sizeof(Com));
      |     ^~~~~~
a.cc:12:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
   11 | #include<set>
  +++ |+#include <cstring>
   12 | #include<tuple>
a.cc: In function 'int main()':
a.cc:44:5: error: 'cou' was not declared in this scope; did you mean 'cos'?
   44 |     cou<<N-K+1<<endl;
      |     ^~~
      |     cos
Language: C++

include<bits/stdc++.h>
using namespace std;
 
int main(){
 ios_base::sync_with_stdio(0); cin.tie(0);
  int k,n; cin >> k >> n;
  cout << k-n << "\n";
  return 0;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:5:2: error: 'ios_base' has not been declared
    5 |  ios_base::sync_with_stdio(0); cin.tie(0);
      |  ^~~~~~~~
a.cc:5:32: error: 'cin' was not declared in this scope
    5 |  ios_base::sync_with_stdio(0); cin.tie(0);
      |                                ^~~
a.cc:7:3: error: 'cout' was not declared in this scope
    7 |   cout << k-n << "\n";
      |   ^~~~
Language: C++

nclude<bits/stdc++.h>
using namespace std;
 
int main(){
 ios_base::sync_with_stdio(0); cin.tie(0);
  int k,n; cin >> k >> n;
  cout << n-k << "\n";
  return 0;
}

Compiler output:
a.cc:1:1: error: 'nclude' does not name a type
    1 | nclude<bits/stdc++.h>
      | ^~~~~~
a.cc: In function 'int main()':
a.cc:5:2: error: 'ios_base' has not been declared
    5 |  ios_base::sync_with_stdio(0); cin.tie(0);
      |  ^~~~~~~~
a.cc:5:32: error: 'cin' was not declared in this scope
    5 |  ios_base::sync_with_stdio(0); cin.tie(0);
      |                                ^~~
a.cc:7:3: error: 'cout' was not declared in this scope
    7 |   cout << n-k << "\n";
      |   ^~~~
Language: C++

#include<bits.stdc++.h>
using namespace std;
int main(){
  int n,k,a=1;cin>>n>>k;
  for(int i=0;i<k;i++){
    a*=n-i;
    a/=i+1;
  }
  cout<<a<<endl;
}

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

import java.util.*;
import java.io.*;
public class ques
{ 
    public static void main(String args[]) 
    { 
       Scanner s=new Scanner(System.in);

   
      int n=s.nextInt();
      int k=s.nextInt();
      
      System.out.println(n+1-k);
    }
}





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

import java.util.*;
import java.io.*;
public class ques
{ 
    public static void main(String args[]) 
    { 
       Scanner s=new Scanner(System.in);

       int n=s.nextInt();
      int k=s.nextInt();
      
      System.out.println(n+1-k);
    }
}

Compiler output:
Main.java:3: error: class ques is public, should be declared in a file named ques.java
public class ques
       ^
1 error
Language: C++

#include<bits/stdc+.h>
using namespace std;
int main()
{
  int n,k;
  cin>>n>>k;
  cout<<n-k+1;
}

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

#include <stdio.h>
int main (void)
{
  int n,k;
  scanf("%d %d",&n,&k);
  printf("%d"n-k+1);
 return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:6:14: error: expected ')' before 'n'
    6 |   printf("%d"n-k+1);
      |         ~    ^
      |              )
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 k=sc.nextInt();
    System.out.print(n-k+1);
  }
}

Compiler output:
Main.java:5: error: cannot find symbol
    Scanner sc = new Scanner(System.In);
                                   ^
  symbol:   variable In
  location: class System
1 error
Language: Java

import java.util.*;

pubilc class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.In);
    int n=sc.nextInt();
    int k=sc.nextInt();
    System.out.print(n-k+1);
  }
}

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

#include<bits.stdc++.h>

int main(){
    int N,K; cin>>N>>K;
    printf("%d",N-K+1);
}

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

package ProgrammingChallenge.diverta2019programmingcontest;

import java.util.Scanner;

/**
 * 1,2,...,Nの整数からK個選ぶ方法は何通り？
 *
 * @author uumee
 *
 */
public class ConsecutiveIntegers {

    /** main */
    public static void main(String[] args) {
	Scanner sc = new Scanner(System.in);
	System.out.println(sc.nextInt() - (sc.nextInt() - 1));
	sc.close();
    }

}


Compiler output:
Main.java:11: error: class ConsecutiveIntegers is public, should be declared in a file named ConsecutiveIntegers.java
public class ConsecutiveIntegers {
       ^
1 error
Language: C++

#include <bits/stdc++.h>
int main(){
  int n,k;
  cin>>n>>k;
  cout<<max(0,n-k+1)<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    4 |   cin>>n>>k;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:5:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    5 |   cout<<max(0,n-k+1)<<endl;
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:5:9: error: 'max' was not declared in this scope; did you mean 'std::max'?
    5 |   cout<<max(0,n-k+1)<<endl;
      |         ^~~
      |         std::max
In file included from /usr/include/c++/14/algorithm:61,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51:
/usr/include/c++/14/bits/stl_algo.h:5716:5: note: 'std::max' declared here
 5716 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
a.cc:5:23: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    5 |   cout<<max(0,n-k+1)<<endl;
      |                       ^~~~
      |                       std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C

#include<stdio.h> 

int main(void){
   int n, k;
   scanf(“%d %d”, &n, &k);
   printf(“%d\n”, n-k+1);
   return 0;
}


Compiler output:
main.c: In function 'main':
main.c:5:10: error: stray '\342' in program
    5 |    scanf(<U+201C>%d %d<U+201D>, &n, &k);
      |          ^~~~~~~~
main.c:5:11: error: expected expression before '%' token
    5 |    scanf(“%d %d”, &n, &k);
      |           ^
main.c:5:16: error: stray '\342' in program
    5 |    scanf(<U+201C>%d %d<U+201D>, &n, &k);
      |                       ^~~~~~~~
main.c:6:11: error: stray '\342' in program
    6 |    printf(<U+201C>%d\n<U+201D>, n-k+1);
      |           ^~~~~~~~
main.c:6:12: error: expected expression before '%' token
    6 |    printf(“%d\n”, n-k+1);
      |            ^
main.c:6:14: error: stray '\' in program
    6 |    printf(“%d\n”, n-k+1);
      |              ^
main.c:6:16: error: stray '\342' in program
    6 |    printf(<U+201C>%d\n<U+201D>, n-k+1);
      |                       ^~~~~~~~
Language: C

#include<stdio.h> 

int main(void){
   int n, k;
   scanf(“%d %d”, &n, &k);
   printf(“%d\n”, n-k*1);
   return 0;
}


Compiler output:
main.c: In function 'main':
main.c:5:10: error: stray '\342' in program
    5 |    scanf(<U+201C>%d %d<U+201D>, &n, &k);
      |          ^~~~~~~~
main.c:5:11: error: expected expression before '%' token
    5 |    scanf(“%d %d”, &n, &k);
      |           ^
main.c:5:16: error: stray '\342' in program
    5 |    scanf(<U+201C>%d %d<U+201D>, &n, &k);
      |                       ^~~~~~~~
main.c:6:11: error: stray '\342' in program
    6 |    printf(<U+201C>%d\n<U+201D>, n-k*1);
      |           ^~~~~~~~
main.c:6:12: error: expected expression before '%' token
    6 |    printf(“%d\n”, n-k*1);
      |            ^
main.c:6:14: error: stray '\' in program
    6 |    printf(“%d\n”, n-k*1);
      |              ^
main.c:6:16: error: stray '\342' in program
    6 |    printf(<U+201C>%d\n<U+201D>, n-k*1);
      |                       ^~~~~~~~
Language: C++

#include<studio.h> 

int main(void){
   int n, k;
   scanf(“%d %d”, &n, &k) ;
   printf(“%d\n”, n-k*1);


   return 0;
}

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

#include<stdio.h>
#include<iostream>
using namespace std;
int main(){
  int N,K;
  cin>>N;
  cin>>K;
  cout<<N-K+1;
  return 0;
}

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