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

#include<iostream>
#include<cstdio>
#include<cmath>
#include<cstring>
#include<string>
#include<stack>
#include<queue>
#include<vector>
#include<algorithm>
#include<iomanip>
typedef long long int ll;
using namespace std;
#define FOR(i,a,b) for (int i=(a);i<(b);i++)
#define REP(i,n) for (unsigned int i=0;i<(n);i++)
#define EREP(i,n) for (int i=1;i<=(n);i++)
#define ALL(a) (a).begin(),(a).end()
//#define EVEL 1

#ifdef EVEL
#define DEB(X) cout << #X << ":" <<X<<" " ;
#define TF(f) f ? cout<<"true  " : cout<<"false ";
#define END cout<<"\n";
#else
#define DEB(X) {}
#define TF(f) {}
#define END {}
#endif
const int MOD =  1000000007 ;
const int INF = 2000000000;


    ll A,B,C,D;
    string S,T;
    ll X[100];
    ll gcd(ll a,ll b){
        if(b==0)return a;
        return gcd(b,a%b);
    }
int main(){
    cin>>A>>B;
    if(A<B)swap(A,B);
    cout<<((A/gcd(A,B))%(B/gcd(A,B))==0?-1:B*B/gcd(A,B)/gcd(A,B))<<endl;
    return 0;


Compiler output:
a.cc: In function 'int main()':
a.cc:43:14: error: expected '}' at end of input
   43 |     return 0;
      |              ^
a.cc:39:11: note: to match this '{'
   39 | int main(){
      |           ^
Language: C++

include<bits/stdc++.h>
using namespace std;
int main()
{ 
    int x,y;
    cin>>x>>y;
    if(x%y)cout<<x;
    else cout<<-1;
    cout<<endl;
    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:6:5: error: 'cin' was not declared in this scope
    6 |     cin>>x>>y;
      |     ^~~
a.cc:7:12: error: 'cout' was not declared in this scope
    7 |     if(x%y)cout<<x;
      |            ^~~~
a.cc:8:10: error: 'cout' was not declared in this scope
    8 |     else cout<<-1;
      |          ^~~~
a.cc:9:5: error: 'cout' was not declared in this scope
    9 |     cout<<endl;
      |     ^~~~
a.cc:9:11: error: 'endl' was not declared in this scope
    9 |     cout<<endl;
      |           ^~~~
Language: C

#include<cstdio>
#include<string>
#include<algorithm>
using namespace std;
int main ()
{
	int x,y;
	scanf("%d%d",&x,&y);
	if(x%y==0){puts("-1");
		return 0;
	}
	printf("%d\n",x);
	return 0;
}

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

#include<cstdio>
#include<string>
#include<algorithm>
using namespace std;
int main ()
{
	int x,y;
	scanf("%d%d",&x,&y);
	if(x%y==o){
		puts("-1");
		return 0;
	}
	printf("%d\n",x);
	return 0;
}

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

import java.util.*;
public class Main
{

public static void main(String[] args) {
	    Scanner in=new Scanner(System.in);
	   long x=in.nextLong();
	   long y=in.nextLong();
      long p=gcd(x,y);
      long  lcm= x*y/p;
      int ok=1;
long ans=-1;
for(long i=x;i<lcm;i+=x)
{
if(i%y==0)
{
ok=0;
break;
}
else {ans=i;break}
}
      if(ok==0)
      System.out.println(-1);
      else
    	  System.out.println(ans);
	    }
	static long gcd (long a,long b) {
		return b==0?a:gcd(b,a%b);
	}
}

Compiler output:
Main.java:20: error: ';' expected
else {ans=i;break}
                 ^
1 error
Language: C++

#include<iostream>//AT3908
int main(){int x,y;if(x%y)cout<<x;else cout<<"-1";return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:2:27: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    2 | int main(){int x,y;if(x%y)cout<<x;else cout<<"-1";return 0;}
      |                           ^~~~
      |                           std::cout
In file included from a.cc:1:
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:2:40: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    2 | int main(){int x,y;if(x%y)cout<<x;else cout<<"-1";return 0;}
      |                                        ^~~~
      |                                        std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

#include <stdio.h>
#include <iostream>
using namespace std;
int main()
{
	ios::sync_with_stdio(false);
	long long int a,b;
	long long int i,s;
	cin>>a>>b;
	if(a%b)
	{
		cout<<a;
	}
	else
	{
		cout<<"-1";
	}
	cout<<endl;


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

#define _USE_MATH_DEFINES
#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
#include<string>
#include<iostream>
#include<iostream>
#include<cctype>
#include<cstdio>
#include<vector>
#include<stack>
#include<queue>
#include <algorithm>
#include<math.h>
#include<set>
#include<map>
#include <sstream>
#include<iomanip>
#include <ctype.h>
using namespace std;

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


int main() {
	long long int a, b;
	cin >> a >> b;
	for (long long int i = a; i <=a*b 1; i++) {
		if (i%a == 0 && i%b) {
			cout << i << endl;
			return 0;
		}
	}
	cout << -1 << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:27:42: error: expected ';' before numeric constant
   27 |         for (long long int i = a; i <=a*b 1; i++) {
      |                                          ^~
      |                                          ;
a.cc:27:44: error: expected ')' before ';' token
   27 |         for (long long int i = a; i <=a*b 1; i++) {
      |             ~                              ^
      |                                            )
a.cc:27:46: error: 'i' was not declared in this scope
   27 |         for (long long int i = a; i <=a*b 1; i++) {
      |                                              ^
Language: C++

#include<iostream>
main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<std::endl;}

Compiler output:
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    2 | main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<std::endl;}
      | ^~~~
a.cc: In function 'int main()':
a.cc:2:52: error: invalid operands of types 'const char [3]' and '<unresolved overloaded function type>' to binary 'operator<<'
    2 | main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<std::endl;}
      |                                                ~~~~^~~~~~~~~~~
Language: C++

#include<iostream>
main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}

Compiler output:
a.cc:2:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    2 | main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}
      | ^~~~
a.cc: In function 'int main()':
a.cc:2:54: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    2 | main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}
      |                                                      ^~~~
      |                                                      std::endl
In file included from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include<iostream>main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}

Compiler output:
a.cc:1:23: warning: extra tokens at end of #include directive
    1 | #include<iostream>main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}
      |                       ^
a.cc:1:9: fatal error: iostream>mai: No such file or directory
    1 | #include<iostream>main(){int x,y;std::cin>>x>>y;std::cout<<x%y?x:"-1"<<endl;}
      |         ^~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    int a,b;
    cin>>a>>b;
    cout<<(a%b==0)?-1:a<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    7 |     cout<<(a%b==0)?-1:a<<endl;
      |                       ~^~~~~~
Language: C++

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

int main(){
	ios_base::sync_with_stdio(false);
	cin.tie(0);
	cin>>x>>y;
	if(x%y==0) cout<<-1<<endl;
	else cout<<x<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:14: error: 'x' was not declared in this scope
    7 |         cin>>x>>y;
      |              ^
a.cc:7:17: error: 'y' was not declared in this scope; did you mean 'yn'?
    7 |         cin>>x>>y;
      |                 ^
      |                 yn
Language: C++

#include <iostream>
#include <cstdlib>
using namespace std;
int a,b;
int main()
{
    cin>>a>>b;
    if(x%y) cout<<x<<endl;
    else puts("-1");
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:8: error: 'x' was not declared in this scope
    8 |     if(x%y) cout<<x<<endl;
      |        ^
a.cc:8:10: error: 'y' was not declared in this scope
    8 |     if(x%y) cout<<x<<endl;
      |          ^
Language: C++

#include <iostream>
using namespace std;
int main(){
  int x,y;
  cin>>x>>y;
  if(x%y==0) cout<<"-1"<<endl;
  else cout<<x<<endl;c
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:22: error: 'c' was not declared in this scope
    7 |   else cout<<x<<endl;c
      |                      ^
Language: C++

#include<iostrem>
using namespace std;
int main()
{
    int x,y;
    cin>>x>>y;
    if(x%y)cout<<x;
    else cout<<-1;
    return 0;
}

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

#include<iostream>
#include<algorithm>
#include<math.h>
#include<cstdio>
#include<ctype.h>
#include<stdio.h>
#include<set>
#include<vector>
#include<map>
#include<functional>
#include<iomanip>
#include<queue>
#include<ciso646>
#include<random>
#include<numeric>
#include<string>
typedef long long ll;
using namespace std;
 
ll gcd(ll a, ll b){
if(a<b){return gcd(b,a);}
else if(a%b){return gcd(b,a%b);}
else{return b;}
}
int main(){
ll x,y;
cin>>x>>>y;
if(x%y==0)
cout<<-1<<endl;
else
cout<<x<<endl;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:27:9: error: expected primary-expression before '>' token
   27 | cin>>x>>>y;
      |         ^
Language: C++

#include <cstdio>
int a,b;
int main()
{
    scanf("%d%d",&a,&b);
    if(a%b!=0)
        printf("%d",x);
    else
        printf("%d",-1);
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:21: error: 'x' was not declared in this scope
    7 |         printf("%d",x);
      |                     ^
Language: C++

# include <bits/stdc++.h> 
using namespace std;
typedef longl ong ll;
int main(){
	ll a,b;
	cin>>a >> b;
	cout << a*(b-1) << endl;
}

Compiler output:
a.cc:3:9: error: 'longl' does not name a type; did you mean 'long'?
    3 | typedef longl ong ll;
      |         ^~~~~
      |         long
a.cc: In function 'int main()':
a.cc:5:9: error: 'll' was not declared in this scope
    5 |         ll a,b;
      |         ^~
a.cc:6:14: error: 'a' was not declared in this scope
    6 |         cin>>a >> b;
      |              ^
a.cc:6:19: error: 'b' was not declared in this scope
    6 |         cin>>a >> b;
      |                   ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{ 
    int x,y;
    cin>>x>>y;
    if(x%y)cout<<x;
    else cout<<-1;
    cout<<endl
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:15: error: expected ';' before '}' token
    9 |     cout<<endl
      |               ^
      |               ;
   10 | }
      | ~
Language: C++

#include <cstdio>
using ll = long long;
int main() {
  int x, y;
  scanf("%d%d", &x, &y);
  if (x % y == 0) puts("-1");
  else {
    ll lcm = x * y * gcd(x, y);
    printf("%lld\n", lcm + x);
  }
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:8:22: error: 'gcd' was not declared in this scope
    8 |     ll lcm = x * y * gcd(x, y);
      |                      ^~~
Language: C++

#include <iostream>
using namespace std;
int main(){
  int x,y;
  cin>>x>>y;
  if(y%x==0) cout<<"-1"<<endl;
  for(long long int i=1;i<100000000000000000){
     if(i%x==0&&i%y!=0){
       cout<<i<<endl;
     }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:45: error: expected ';' before ')' token
    7 |   for(long long int i=1;i<100000000000000000){
      |                                             ^
      |                                             ;
Language: C++

#include <iostream>
using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  if(y%x==0) cout<<"-1"<<endl;
  for(long long int i=1;i<100000000000000000){
     if(i%x==0&&i%y!=0){
       cout<<i<<endl;
     }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:6: error: 'y' was not declared in this scope
    6 |   if(y%x==0) cout<<"-1"<<endl;
      |      ^
a.cc:6:8: error: 'x' was not declared in this scope
    6 |   if(y%x==0) cout<<"-1"<<endl;
      |        ^
a.cc:7:45: error: expected ';' before ')' token
    7 |   for(long long int i=1;i<100000000000000000){
      |                                             ^
      |                                             ;
a.cc:8:11: error: 'x' was not declared in this scope
    8 |      if(i%x==0&&i%y!=0){
      |           ^
a.cc:8:19: error: 'y' was not declared in this scope
    8 |      if(i%x==0&&i%y!=0){
      |                   ^
Language: C++

#include <bits/stdc++.h>

using namespace std;

long long int X,Y,ans;
ans=1;

int main(){
    cin>>X>>Y;
    int dispo=X%Y;
    for(int i=1;i*X<=1e18;i++){
        ans=(i*dispo)%Y;
        if(ans!=0){
            cout<<X*i<<endl;
            return 0;
        }
    }
    cout<<"-1"<<endl;
}


Compiler output:
a.cc:6:1: error: 'ans' does not name a type
    6 | ans=1;
      | ^~~
Language: C++

#include <bits/stdc++.h>

using namespace std;

long long int X,Y,ans;

int main(){
    cin>>X>>Y;
    if(Y==X){
        cout<<"-1"<<endl;
        return 0;
    }
    for(int i=1;i*X<=1e18;i++){
        ans *= (X*i)%Y;
        if((ans==0){
            cout<<X*i<<endl;
            return 0;
        }
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:20: error: expected ')' before '{' token
   15 |         if((ans==0){
      |           ~        ^
      |                    )
a.cc:19:5: error: expected primary-expression before '}' token
   19 |     }
      |     ^
Language: C++

#include<iostream>
using namespace std;
int main()
{ 
    int x,y;
    cin>>x>>y;
    cout<< !x%y ? -1:x <<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    7 |     cout<< !x%y ? -1:x <<endl;
      |                      ~~^~~~~~
Language: C++

#include <iostream>
using namespace std;
int main() {
    int x,y;
    cin >> x >> y;
    cout << !(x%y) ? -1 : x << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:29: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    6 |     cout << !(x%y) ? -1 : x << endl;
      |                           ~~^~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
    int a,b;
    scanf("%d%d",&a,&b);
    if(a%b) printf("%d\n",a);return 0;
    else{printf("-1\n");}
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'else' without a previous 'if'
    7 |     else{printf("-1\n");}
      |     ^~~~
Language: C++

#include<iostream>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<cstdio>
using namespace std;
long long a,b,ans=65,n;
long long Read() {
	long long x=0,f=1;
	char c=getchar();
	while(c<'0'||c>'9') {
		if(c=='-')f=-1;
		c=getchar();
	}
	while(c>='0'&&c<='9')x=x*10+c-'0',c=getchar();
	return x*f;
}
int ar[10000000];
int main() {
	int x=Read(),y=Read();
	if(x%y)cout<<x;
	else cout<<-1;
	cout<<endl;a
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:23:21: error: expected ';' before 'return'
   23 |         cout<<endl;a
      |                     ^
      |                     ;
   24 |         return 0;
      |         ~~~~~~
Language: C++

#include <iostream>
using namespace std;

int main(){
    unsigned long long x,y;
    cin>>x>>y;
    if(y%x==0){
            cout<<-1<<endl;
        }else{
            cout<<x<<endl;
        }
    }
}

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

#include<iostream>
unsigned long long a,b;
int main()
{
    cout<<"-1";
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    5 |     cout<<"-1";
      |     ^~~~
      |     std::cout
In file included from a.cc:1:
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

#include<cstdio>
#include<cstring>
#include<iomanip>
#include<iostream>
#include<algorithm>
#include<cmath>
#include<ctime>
#include<map>
#include<set>
#include<vector>
#include<queue>
#include<bitset>
#include<stack>
#include<cassert>
#define F first
#define S second
#define mp make_pair
#define pii pair<int,int>
#define pb push_back
#define mem(x,y) memset(x,y,sizeof x)
#define sqr(x) ((x)*(x))
using namespace std;
typedef long long ll;
typedef double db;
const int INF=2e9;
const db eps=1e-8;
template<typename T>
inline void read(T &x)                        
{
	x=0; int f=1; char ch=getchar();
	while( (ch<'0' || ch>'9') && ch!='-') ch=getchar(); if(ch=='-') {f=-1; ch=getchar();}
	while(ch>='0' && ch <='9') x=x*10+ch-'0',ch=getchar();
	x*=f;
}
//==========================head template==========================
const int N=100010;
vector<int> E[N];
int w[N],vis[N];
int bestidx,bestval;
void dfs(int x){
    vis[x]=1;
    if(w[x]<bestval){
        bestval=w[x];
        bestidx=x;
    }
    for(auto u:E[x]){
        if(!vis[u]) dfs(u);
    }
}
int main(){
    LL ans=0;
    int n,m,cnt=0;
    scanf("%d %d",&n,&m);
    for(int i=0;i<n;i++) scanf("%d",&w[i]);
    for(int i=1;i<=m;i++){
        int x,y;
        scanf("%d %d",&x,&y);
        E[x].push_back(y);
        E[y].push_back(x);
    }
    for(int i=0;i<n;i++){
        if(!vis[i]){
            bestval=2e9;
            dfs(i);
            ans+=bestval;
            w[bestidx]=2e9;
            cnt++;
        }
    }
    if(cnt==1) {printf("0\n");return 0;}
    sort(w,w+n);
    for(int i=0;i<cnt-2;i++){
        if(w[i]==2e9){
            printf("Impossible\n");
            return 0;
        }
        ans+=w[i];
    }
    printf("%lld\n",ans);
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:51:5: error: 'LL' was not declared in this scope; did you mean 'll'?
   51 |     LL ans=0;
      |     ^~
      |     ll
a.cc:65:13: error: 'ans' was not declared in this scope; did you mean 'abs'?
   65 |             ans+=bestval;
      |             ^~~
      |             abs
a.cc:77:9: error: 'ans' was not declared in this scope; did you mean 'abs'?
   77 |         ans+=w[i];
      |         ^~~
      |         abs
a.cc:79:21: error: 'ans' was not declared in this scope; did you mean 'abs'?
   79 |     printf("%lld\n",ans);
      |                     ^~~
      |                     abs
Language: C++

#include <iostream>
using namespace std;

int main()
{   int x,y;
    cin>>x>>y;
    if (x%y==0) break;
    else{
        for (int i=x+1;i<x*y;i++){
            if (i%x==0&&i%y!=0) cout<<i;
        }
        cout<<-1;}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: break statement not within loop or switch
    7 |     if (x%y==0) break;
      |                 ^~~~~
Language: C++

#include<iostream>
uisng namespace std;
int main()
{int a, b; cin>>a>>b; cout<<a%b?a:-1;}

Compiler output:
a.cc:2:1: error: 'uisng' does not name a type
    2 | uisng namespace std;
      | ^~~~~
a.cc: In function 'int main()':
a.cc:4:12: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    4 | {int a, b; cin>>a>>b; cout<<a%b?a:-1;}
      |            ^~~
      |            std::cin
In file included 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:4:23: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    4 | {int a, b; cin>>a>>b; cout<<a%b?a:-1;}
      |                       ^~~~
      |                       std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

#include<cstdio>
#include<algortihm>
using namespace std;
#define LL long long
LL a,b;
int main()
{
	scanf("%lld%lld",&a,&b);
	if(a%b==0)
		printf("-1\n");
	else
		printf("%lld\n",a);
}

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

#include<cstdio>
#include<algorithm>
using namespace std;
int H, W, N;
struct point {
	int x, y;
}w[31];
int i, X[31], Y[31], CX, CY;
struct point {
	int b, e;
}XX[91], YY[91];
int D[91][91][4];
int main() {
	int i, j;
	scanf("%d%d%d", &H, &W, &N);
	for (i = 0; i < N; i++) {
		scanf("%d%d", &w[i].x, &w[i].y);
		w[i].x++, w[i].y++;
		X[CX++] = w[i].x;
		Y[CY++] = w[i].y;
	}
	X[CX++] = 0; X[CX++] = H + 1;
	Y[CY++] = 0; Y[CY++] = W + 1;
	sort(X, X + CX); sort(Y, Y + CY);
	CX = unique(X, X + CX) - X;
	CY = unique(Y, Y + CY) - Y;
	int c1 = 0, c2 = 0;
	for (i = 0; i < CX-1; i++) {
		if (X[i] >= 1 && X[i] <= H) {
			XX[++c1] = { X[i],X[i] };
		}
		if (X[i + 1] - X[i] >= 2) XX[++c1] = { X[i] + 1,X[i + 1] - 1 };
	}
	for (i = 0; i < CY - 1; i++) {
		if (Y[i] >= 1 && Y[i] <= W) {
			YY[++c2] = { Y[i],Y[i] };
		}
		if (Y[i + 1] - Y[i] >= 2) YY[++c1] = { Y[i] + 1,Y[i + 1] - 1 };
	}
	CX = c1, CY = c2;
}

Compiler output:
a.cc:9:8: error: redefinition of 'struct point'
    9 | struct point {
      |        ^~~~~
a.cc:5:8: note: previous definition of 'struct point'
    5 | struct point {
      |        ^~~~~
a.cc: In function 'int main()':
a.cc:30:48: error: cannot convert '<brace-enclosed initializer list>' to 'int' in assignment
   30 |                         XX[++c1] = { X[i],X[i] };
      |                                                ^
a.cc:32:78: error: cannot convert '<brace-enclosed initializer list>' to 'int' in assignment
   32 |                 if (X[i + 1] - X[i] >= 2) XX[++c1] = { X[i] + 1,X[i + 1] - 1 };
      |                                                                              ^
a.cc:36:48: error: cannot convert '<brace-enclosed initializer list>' to 'int' in assignment
   36 |                         YY[++c2] = { Y[i],Y[i] };
      |                                                ^
a.cc:38:78: error: cannot convert '<brace-enclosed initializer list>' to 'int' in assignment
   38 |                 if (Y[i + 1] - Y[i] >= 2) YY[++c1] = { Y[i] + 1,Y[i + 1] - 1 };
      |                                                                              ^
Language: C++

#include<iostream>
#include<cstdio>
#include<cstdlib>
using namespace std;
int main()
{
	const int maxn=1e18;
	int x,y;
	cin>>x>>y;
	if(x>y&&x%y==0) cout<<-1<<endl;
	for(int i=x+1;i<=max;++i)
		if(i%x==0&&i%y!=0) { cout<<i<<endl; break; }
	return 0;
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: warning: overflow in conversion from 'double' to 'int' changes value from '1.0e+18' to '2147483647' [-Woverflow]
    7 |         const int maxn=1e18;
      |                        ^~~~
a.cc:11:24: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<='
   11 |         for(int i=x+1;i<=max;++i)
      |                       ~^~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
	int X,Y;
	long long n=2;
	cin>>X>>Y;
	if(X%Y==0)
		cout<<"-1"<<endl;
	else
		cout<<x<<endl;
	return 0;
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:10:23: error: 'x' was not declared in this scope
   10 |                 cout<<x<<endl;
      |                       ^
Language: C++

#include<iostream>
using namespace std;
typedef long long ll;

int main() {
    // 整数の入力
    ll x, y;
    cin >> x >> y;

    if (x % y == 0) {
        cout << -1 << endl;
    } else {
        cout << x << endl;
    }
    return 0;

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

#include <cstdio>
#include <string>

using namespace std;

int gcd(int a, int b){
    if(a == 0) return b;
    return gcd(b%a, a);
}

int main(void){
  int x,y;
  std::cin >> x >> y;

  int res = x/y;
  if(res * y == x) std::cout << "-1";
  else{
      int g = gcd(x,y);
     std::cout << g * x;
  }

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:8: error: 'cin' is not a member of 'std'
   13 |   std::cin >> x >> y;
      |        ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    2 | #include <string>
  +++ |+#include <iostream>
    3 | 
a.cc:16:25: error: 'cout' is not a member of 'std'
   16 |   if(res * y == x) std::cout << "-1";
      |                         ^~~~
a.cc:16:25: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:19:11: error: 'cout' is not a member of 'std'
   19 |      std::cout << g * x;
      |           ^~~~
a.cc:19:11: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: Java

import java.util.*;

public class Main2 {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int a = sc.nextInt();
		int b = sc.nextInt();
		
		System.out.println(b%a==0?-1:a);	

		}

}

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

#include <cstdio>
#include <string>

using namespace std;

int gcd(int a, int b){
    if(a == 0) return b;
    return gcd(b%a, a);
}

int main(void){
  int x,y;
  cin >> x >> y;

  int res = x/y;
  if(res * y == x) std::cout << "-1" << std::endl;
  else{
      int g = gcd(x,y);
     std::cout << g * x << std::endl;
  }

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:3: error: 'cin' was not declared in this scope
   13 |   cin >> x >> y;
      |   ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    2 | #include <string>
  +++ |+#include <iostream>
    3 | 
a.cc:16:25: error: 'cout' is not a member of 'std'
   16 |   if(res * y == x) std::cout << "-1" << std::endl;
      |                         ^~~~
a.cc:16:25: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:16:46: error: 'endl' is not a member of 'std'
   16 |   if(res * y == x) std::cout << "-1" << std::endl;
      |                                              ^~~~
a.cc:3:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    2 | #include <string>
  +++ |+#include <ostream>
    3 | 
a.cc:19:11: error: 'cout' is not a member of 'std'
   19 |      std::cout << g * x << std::endl;
      |           ^~~~
a.cc:19:11: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:19:33: error: 'endl' is not a member of 'std'
   19 |      std::cout << g * x << std::endl;
      |                                 ^~~~
a.cc:19:33: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include <cstdio>
#include <string>

using namespace std;

int gcd(int a, int b){
    if(a == 0) return b;
    return gcd(b%a, a);
}

int main(void){
  int x,y;
  cin >> x >> y;

  int res = x/y;
  if(res * y == x) cout << -1 << endl;
  else{
      int g = gcd(x,y);
     cout << g * x << endl;
  }

  


  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:3: error: 'cin' was not declared in this scope
   13 |   cin >> x >> y;
      |   ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    2 | #include <string>
  +++ |+#include <iostream>
    3 | 
a.cc:16:20: error: 'cout' was not declared in this scope
   16 |   if(res * y == x) cout << -1 << endl;
      |                    ^~~~
a.cc:16:20: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:16:34: error: 'endl' was not declared in this scope
   16 |   if(res * y == x) cout << -1 << endl;
      |                                  ^~~~
a.cc:3:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    2 | #include <string>
  +++ |+#include <ostream>
    3 | 
a.cc:19:6: error: 'cout' was not declared in this scope
   19 |      cout << g * x << endl;
      |      ^~~~
a.cc:19:6: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:19:23: error: 'endl' was not declared in this scope
   19 |      cout << g * x << endl;
      |                       ^~~~
a.cc:19:23: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

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

int main(){
	int a,b;
	scanf("%d%d",&a,&b);
	if(a==b|| (a>b && a%b==0)){
		printf("-1\n");
	}
	else {
		if(a*2!=b)printf("%d\n",a*2);
		else printf("%d\n",3*b)
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:40: error: expected ';' before '}' token
   13 |                 else printf("%d\n",3*b)
      |                                        ^
      |                                        ;
   14 |         }
      |         ~
Language: C

#include<stdio.h>


int main(){
unsigned long long a;
unsigned long long b;
unsigned long long i;
unsigned long longc;
scanf("%lld%lld",&a,&b);
c=a;
for(i=1;i<1000000000000000000;i++){
	
	c*=i;
	if(c%a==0&&a%b!=0&&i>1){
		
		
		printf("%lld\n",c);
		break;
	}
	if(i>10000000){
		printf("-1\n");
		break;
	}
	
	
}

return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:1: error: 'c' undeclared (first use in this function)
   10 | c=a;
      | ^
main.c:10:1: note: each undeclared identifier is reported only once for each function it appears in
Language: Java

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class TwoIntegers {
    void solve() throws IOException {
        long x = getLong();
        long y = getLong();
        if(x == y){
            System.out.println(-1);
            return;
        }
        for(long i = 2; i < 1000000; ++i){
            long res = (long)(x * i);
            if(res % y != 0){
                System.out.println(res);
                return;
            }
        }
        System.out.println(-1);
    }

    BufferedReader bufferedReader;
    PrintWriter output;
    StringTokenizer tokenizer;

    public static void main(String[] args) throws IOException {
        TwoIntegers contest = new TwoIntegers();
        contest.run();
    }

    public String nextToken() throws IOException {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            tokenizer = new StringTokenizer(bufferedReader.readLine());
        }
        return tokenizer.nextToken();
    }

    public int getInt() throws IOException {
        return Integer.parseInt(nextToken());
    }

    public long getLong() throws IOException {
        return Long.parseLong(nextToken());
    }

    public double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }

    void run() throws IOException {
        bufferedReader = new BufferedReader(new InputStreamReader(System.in));
        output = new PrintWriter(System.out);
        solve();
    }

}


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

import java.util.Scanner;
public class Two_Integers {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int x = sc.nextInt();
		int y = sc.nextInt();
		boolean isHumJudge = false;
			for(int a = 2;x*a < 1000;a++){
				if(x*a%y != 0){
					isHumJudge = true;
					System.out.println(x*a);
					break;
				}
			}
		if(isHumJudge == false){
			System.out.println(-1);
		}
	}

}


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

import java.util.Scanner;

class Main{
    public static void main(String[] args){
        Scanner scan = new Scanner(Systme.in);

        int X = scan.nextInt();
        int Y = scan.nextInt();
        if(X%Y==0)System.out.println(-1);
        else System.out.println(X);
    }
}

Compiler output:
Main.java:5: error: cannot find symbol
        Scanner scan = new Scanner(Systme.in);
                                   ^
  symbol:   variable Systme
  location: class Main
1 error
Language: C++

#include"bits/stdc++.h"
using namespace std;
int main(){
int x y;
cin>>x>>y;
cout<<(x%y?x:-1);
}


Compiler output:
a.cc: In function 'int main()':
a.cc:4:7: error: expected initializer before 'y'
    4 | int x y;
      |       ^
a.cc:5:6: error: 'x' was not declared in this scope
    5 | cin>>x>>y;
      |      ^
a.cc:5:9: error: 'y' was not declared in this scope; did you mean 'yn'?
    5 | cin>>x>>y;
      |         ^
      |         yn
Language: Java

import java.math.BigInteger;
import java.util.*;

public class bbb
{

    public  static void main(String args[])
    {
		Scanner in = new Scanner(System.in);
		int a = in.nextInt();
		int b = in.nextInt();
		if(a % b == 0)
		{
			System.out.println("-1");
		}else
		{
			System.out.printf("%d\n",a);
		}
    }
}

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

import java.math.BigInteger;
import java.util.*;

public class bbb
{

    public  static void main(String args[])
    {
		Scanner in = new Scanner(System.in);
		int a = in.nextInt();
		int b = in.nextInt();
		if(a % b == 0)
		{
			System.out.println("-1");
		}else
		{
			System.out.printf("%d\n",a);
		}
    }
}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.math.BigInteger;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:2:1: error: 'import' does not name a type
    2 | import java.util.*;
      | ^~~~~~
a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:4:1: error: expected unqualified-id before 'public'
    4 | public class bbb
      | ^~~~~~
Language: C++

#include <bits/stdc++.h>
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define sz(x) x.size()
#define all(x) x.begin(),x.end()
#define forn(i,n) for(int i=0;i<n;++i)
#define repn(i,n) for(int i=1;i<=n;++i)
#define TC(n) while(n--)
#define forb(i,n) for(int i=n-1;i>=0;--i)
#define repb(i,n) for(int i=n;i>=1;--i)

typedef long long LL;
typedef unsigned long long ULL;

using namespace std;
int x,y;
bool cek = false;
int main(){
	scanf("%d%d",&x,&y);
	if(!(x%y) || ){
		printf("-1\n");
	}else{
		printf("%d\n", x);
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:22: error: expected primary-expression before ')' token
   21 |         if(!(x%y) || ){
      |                      ^
Language: C++

#include<iostream>
int main()
{
    long long x,y;
    std::cin>>x>>y;
    std::cout<<(x%y==0?-1:x*(y-1))<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:37: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    6 |     std::cout<<(x%y==0?-1:x*(y-1))<<endl;
      |                                     ^~~~
      |                                     std::endl
In file included from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include<iostream>
using namespace std;
int main(){
long long int a ,b ; 
cin >> a >> b ;
if(a==b){
cout << "-1";
}
else{
if(b!=2){
cout << a*2 ;
}
else{
cout << a*3;
}
return 0;
}

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

#include <iostream>
int main(void)
{
	long long x,y;
	cin >> x >> y;
	if(x%y==0) cout << -1;
	else cout << x;
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |         cin >> x >> y;
      |         ^~~
      |         std::cin
In file included 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:6:20: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    6 |         if(x%y==0) cout << -1;
      |                    ^~~~
      |                    std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:7:14: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |         else cout << x;
      |              ^~~~
      |              std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

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

int main() {
    int n;
    cin >> n;
    int a[2][n];
    for(int j = 0; j < 2; ++j) {
        for(int i = 0; i < n; ++i) {
            cin >> a[j][i];
        }
    }
    int cnt1 = 0, cnt2 = 0;
    for(int i = 0; i < n; ++i) {
        if(a[0][i] < a[1][i]) {
            if((a[0][i] - a[1][i]) & 1) cnt2++;
            cnt1 += (a[1][i] - a[0][i]) >> 1;
        }
        else {
            cnt2 += a[0][i] - a[1][i];
        }
    }
    cout << ((cnt1 == cnt2) || (cnt1 < cnt && (cnt2 - cnt1 % 2 == 0))? "Yes" : "No") << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:23:40: error: 'cnt' was not declared in this scope; did you mean 'cnt2'?
   23 |     cout << ((cnt1 == cnt2) || (cnt1 < cnt && (cnt2 - cnt1 % 2 == 0))? "Yes" : "No") << endl;
      |                                        ^~~
      |                                        cnt2
Language: C++

#include<iostream>
using namespace std;
#define E 1000000000
int main()
{
	int n;
	long long a[10000],b[10000],suma,sumb,p;
	cin>>n;
	for(int i=1;i<=n;i++){
	cin>>a[i],suma+=a[i];}
	for(int i=1;i<=n;i++){
	cin>>b[i],sumb+=b[i];}
	p=sumb-suma;
	if(p<0)
	cout<<"No";
	else
	{
		long long ans=0;
		for(int i=1;i<=n;i++)
		{
			cnt+=(b[i]-a[i]+1)/2;
		}
		if(cnt>p)cout<<"No";
		else cout<<"Yes";
	}
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:25: error: 'cnt' was not declared in this scope; did you mean 'int'?
   21 |                         cnt+=(b[i]-a[i]+1)/2;
      |                         ^~~
      |                         int
a.cc:23:20: error: 'cnt' was not declared in this scope; did you mean 'int'?
   23 |                 if(cnt>p)cout<<"No";
      |                    ^~~
      |                    int
Language: C++

#include <ios>
using namespace std;
using ll = long long;
int main()
{
  long long a,b;
  cin >> a >> b;
  cout << (a%b == 0?-1:a)<<endl;
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'cin' was not declared in this scope
    7 |   cin >> a >> b;
      |   ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include <ios>
  +++ |+#include <iostream>
    2 | using namespace std;
a.cc:8:3: error: 'cout' was not declared in this scope
    8 |   cout << (a%b == 0?-1:a)<<endl;
      |   ^~~~
a.cc:8:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:8:28: error: 'endl' was not declared in this scope
    8 |   cout << (a%b == 0?-1:a)<<endl;
      |                            ^~~~
a.cc:2:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    1 | #include <ios>
  +++ |+#include <ostream>
    2 | using namespace std;
Language: C++

#include<stdio.h>
#include<string.h>
#include<algorithm>
using namespace std;
#define N 100010
int vis[N]
int main()
{
    long long x,y,z;
    scanf("%lld%lld",&x,&y);
    if(x==y)
    {
        printf("-1\n");
        return 0;
    }
    for(long long i=2;i<=100000;i++)
    {
        z=x*i;
        if(z%y)
        {
            printf("%lld\n",z);
            return 0;
        }
    }
    printf("-1\n");
    return 0;
}


Compiler output:
a.cc:7:1: error: expected initializer before 'int'
    7 | int main()
      | ^~~
Language: C++


#define MAX 1000
#define MOD 1000000007


int main()
{
    lli x, y;
    cin >> x >> y;
    if(x == y)
        cout << -1;
    else
    {
        for(int i = 2; ; i++)
        {
            if((x * i) % y != 0)
            {
                cout << x * i ;
                return 0;
            }
        }

        cout << -1;
    }
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:5: error: 'lli' was not declared in this scope
    8 |     lli x, y;
      |     ^~~
a.cc:9:5: error: 'cin' was not declared in this scope
    9 |     cin >> x >> y;
      |     ^~~
a.cc:9:12: error: 'x' was not declared in this scope
    9 |     cin >> x >> y;
      |            ^
a.cc:9:17: error: 'y' was not declared in this scope
    9 |     cin >> x >> y;
      |                 ^
a.cc:11:9: error: 'cout' was not declared in this scope
   11 |         cout << -1;
      |         ^~~~
a.cc:18:17: error: 'cout' was not declared in this scope
   18 |                 cout << x * i ;
      |                 ^~~~
a.cc:23:9: error: 'cout' was not declared in this scope
   23 |         cout << -1;
      |         ^~~~
Language: C++

#include <cstdio>
int main(){
    ll a,b,ans=-1;scanf("%lld %lld",&a,&b);
    for(int i=2;i*a<1e18;++i)if((i*a)%b) {ans = i*a;break;}
    printf("%lld",ans);
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:5: error: 'll' was not declared in this scope
    3 |     ll a,b,ans=-1;scanf("%lld %lld",&a,&b);
      |     ^~
a.cc:3:38: error: 'a' was not declared in this scope
    3 |     ll a,b,ans=-1;scanf("%lld %lld",&a,&b);
      |                                      ^
a.cc:3:41: error: 'b' was not declared in this scope
    3 |     ll a,b,ans=-1;scanf("%lld %lld",&a,&b);
      |                                         ^
a.cc:4:43: error: 'ans' was not declared in this scope
    4 |     for(int i=2;i*a<1e18;++i)if((i*a)%b) {ans = i*a;break;}
      |                                           ^~~
a.cc:5:19: error: 'ans' was not declared in this scope
    5 |     printf("%lld",ans);
      |                   ^~~
Language: C++

#include <cstdio>
#include <cstdlib>
#include <algorithm>
#include <vector>
#include <cstring>
#include <queue>
#include <map>
#include <set>
#include <string>
#include <cmath>

using namespace std;
typedef long long int ll;
typedef pair <int,int> P;

int main() {
  int x, y;
  scanf("%d %d", &x, &y);
  if (y%x == 0)
    puts("-1");
  else
    printf("%d\n", x);
  return 0;

Compiler output:
a.cc: In function 'int main()':
a.cc:23:12: error: expected '}' at end of input
   23 |   return 0;
      |            ^
a.cc:16:12: note: to match this '{'
   16 | int main() {
      |            ^
Language: C++

    #include<bits/stdc++.h>
    using namespace std ; 
     
    int main()
    {
    	long long x , y ; 
     cin >> x >> y ;
if(x%y == 0 )

    }

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

#include<cstdio>
 
using namespace std;
 
int main() 
{
	int n,m;
	while(cin >> n >> m)
	{
		if(n % m == 0 || m % n == 0)  printf("-1\n");
		else printf("%d\n",n);
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:15: error: 'cin' was not declared in this scope
    8 |         while(cin >> n >> m)
      |               ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include<cstdio>
  +++ |+#include <iostream>
    2 |
Language: C++

#include <iostream>
#include <vector>
using namespace std;
int main(){
int N;
cin>>N;
vector<long long> a(N),b(N);
for(int i=0;i<N;i++)cin>>a[i];
for(int i=0;i<N;i++)cin>>b[i];
long long dif=0;//b-a
for(int i=0;i<N;i++)dif-=a[i];
for(int i=0;i<N;i++)dif+=b[i];
logn long act=0;
for(int i=0;i<N;i++){
int d=b[i]-a[i];
if(d>0)act+=(d+1)/2;
}
cout<<((dif>=act)?"Yes":"No")<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:1: error: 'logn' was not declared in this scope; did you mean 'long'?
   13 | logn long act=0;
      | ^~~~
      | long
a.cc:16:8: error: 'act' was not declared in this scope
   16 | if(d>0)act+=(d+1)/2;
      |        ^~~
a.cc:18:14: error: 'act' was not declared in this scope
   18 | cout<<((dif>=act)?"Yes":"No")<<endl;
      |              ^~~
Language: C++

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


int main() {
	int x, y;
	cin >> x >> y;
	cout<<(y%x==0)?x:-1<<endl;
	
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:28: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    9 |         cout<<(y%x==0)?x:-1<<endl;
      |                          ~~^~~~~~
Language: C++

    #include <iostream>
     
    using namespace std;
     
    int main() {
    	unsigned long long X;
    	unsigned long long Y;
    	cin >> X;
    	cin >> Y;
    	if (X%Y == 0) {
    		cout << -1 << endl;
　　　　　return 0;
    	}
    	cout << X << endl;
    	return 0;
    }

Compiler output:
a.cc:12:1: error: extended character 　 is not valid in an identifier
   12 | 　　　　　return 0;
      | ^
a.cc:12:1: error: extended character 　 is not valid in an identifier
a.cc:12:1: error: extended character 　 is not valid in an identifier
a.cc:12:1: error: extended character 　 is not valid in an identifier
a.cc:12:1: error: extended character 　 is not valid in an identifier
a.cc: In function 'int main()':
a.cc:12:1: error: '\U00003000\U00003000\U00003000\U00003000\U00003000return' was not declared in this scope
   12 | 　　　　　return 0;
      | ^~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
#define rep(i,a,b) for(int i=a;i < b;i++)
#define rrep(i,a,b) for(int i=b ; i > a ; i--)
#define pb push_back
#define mp make_pair
#define F first
#define S second
#define endl '\n'
#define check1(a) cerr << a << endl
#define check2(a,b) cerr << a << "|" << b << endl
using namespace std;
typedef long long ll;
typedef long double ld;
typedef vector<int> vi;
/*----------------------------------------------*/
int main()
{
	ll x,y;
	cin >> x >> y;
	if(x == y){
		cout << "-1" ;
		return 0;}
	ll gc = __gcd(x,y);
	ll lc = (x*y)/gc;
	if(lc-x <= 0){
		cout << "-1";
		return 0;
	else{
		cout << x;}
		            

	
	
	

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:28:9: error: expected '}' before 'else'
   28 |         else{
      |         ^~~~
a.cc:25:22: note: to match this '{'
   25 |         if(lc-x <= 0){
      |                      ^