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

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

int main() {
    int a,b,c;
    cin >> a >> b >> c;
    if(b-a==c-b) cout << "YES" << endl;
    else cout << "NO" << endl;
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namespendl'
    2 | using namespendl;ace std;
      |       ^~~~~~~~~~
a.cc:2:18: error: 'ace' does not name a type
    2 | using namespendl;ace std;
      |                  ^~~
a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |     cin >> a >> b >> c;
      |     ^~~
      |     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:7:18: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |     if(b-a==c-b) cout << "YES" << 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:7:35: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |     if(b-a==c-b) cout << "YES" << 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)
      |     ^~~~
a.cc:8:10: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |     else cout << "NO" << 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:8:26: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |     else cout << "NO" << endl;
      |                          ^~~~
      |                          std::endl
/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()
{
long int a,b,c;
scanf("%ld%ld%ld",&a,&b,&c);
if((a<b && b<c && b-a==c-d) || (a>b && b>c && a-b==b-c))
{
    printf("YES");
}else{
    printf("NO");
}

    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:26: error: 'd' undeclared (first use in this function)
    7 | if((a<b && b<c && b-a==c-d) || (a>b && b>c && a-b==b-c))
      |                          ^
main.c:7:26: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>

int main()
{
long int a,b,c;
scanf("%ld%ld%ld",&a,&b,&c);
if(a<b && b<c && b-a==c-d)
{
    printf("YES");
}else{
    printf("NO");
}

    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:25: error: 'd' undeclared (first use in this function)
    7 | if(a<b && b<c && b-a==c-d)
      |                         ^
main.c:7:25: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <bits/stdc++.h>
typedef long long ll;

ll a, b, c;

int main() {
  cin >> a >> b >> c;
  cout << (b-a == c-b ? "YES" : "NO") << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 |   cin >> a >> b >> c;
      |   ^~~
      |   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:8:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |   cout << (b-a == c-b ? "YES" : "NO") << 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:8:42: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |   cout << (b-a == c-b ? "YES" : "NO") << 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>
#include<stdlib.h>
#include<string.h>
int main(){
	int a,b,c;
	int strcmp(char a,char b);
	scanf("%d",&a);
	scanf("%d",&b);
	scanf("%d",&c);
	if(strcmp(b-a,c-b)==0){
	printf("Yes\n");
	}else{
	printf("No\n");}
	
	system("pause");
	return 0;
}

Compiler output:
/usr/bin/ld: /tmp/ccleLDON.o: in function `main':
a.cc:(.text+0x80): undefined reference to `strcmp(char, char)'
collect2: error: ld returned 1 exit status
Language: C++

#include<stdio.h>
#include<stdlib.h>
#include<string.h>
int main(){
	int a,b,c;
	int strcmp(char*a,char*b);
	scanf("%d",&a);
	scanf("%d",&b);
	scanf("%d",&c);
	if(strcmp(b-a,c-b)==0){
	printf("Yes\n");
	}else{
	printf("No\n");}
	
	system("pause");
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:20: error: invalid conversion from 'int' to 'char*' [-fpermissive]
   10 |         if(strcmp(b-a,c-b)==0){
      |                   ~^~
      |                    |
      |                    int
a.cc:6:25: note:   initializing argument 1 of 'int strcmp(char*, char*)'
    6 |         int strcmp(char*a,char*b);
      |                    ~~~~~^
a.cc:10:24: error: invalid conversion from 'int' to 'char*' [-fpermissive]
   10 |         if(strcmp(b-a,c-b)==0){
      |                       ~^~
      |                        |
      |                        int
a.cc:6:32: note:   initializing argument 2 of 'int strcmp(char*, char*)'
    6 |         int strcmp(char*a,char*b);
      |                           ~~~~~^
Language: C++

#include<stdio.h>
#include<stdlib.h>
#include<string.h>
int main(){
	int a,b,c;
	int strcmp(char a,char b);
	scanf("%d",&a);
	scanf("%d",&b);
	scanf("%d",&c);
	if(strcmp(b-a,c-b)==0){
	printf("Yes\n");
	}else{
	printf("No\n");}
	
	system("pause");
	return 0;
}

Compiler output:
/usr/bin/ld: /tmp/ccY17kTm.o: in function `main':
a.cc:(.text+0x80): undefined reference to `strcmp(char, char)'
collect2: error: ld returned 1 exit status
Language: C++

#include<stdio.h>
#include<stdlib.h>
int main(){
	int a,b,c;
	int strcmp(char a,char b);
	scanf("%d",&a);
	scanf("%d",&b);
	scanf("%d",&c);
	if(strcmp(b-a,c-b)==0){
	printf("Yes/n");
	}else{
	printf("No\n");}
	system("pause");
	return 0;
}

Compiler output:
/usr/bin/ld: /tmp/ccSybnC6.o: in function `main':
a.cc:(.text+0x80): undefined reference to `strcmp(char, char)'
collect2: error: ld returned 1 exit status
Language: C

#include<stdio.h>
int a,b,c;

int main(){
	scanf("%d %d %d",&a,&b,&c);
	if(a+c==2*b)
 		printf("YES");
 	else
 		printf("NO");
	}	
}


Compiler output:
main.c:11:1: error: expected identifier or '(' before '}' token
   11 | }
      | ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>C;
    if(b-a==c-b)cout<<"YES";
    else cout<<"NO";
    cout<<endl;
    return 0;
}

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

#include<bits/stdc++.h>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>C;
    if(b==(a+c)/2)cout<<"YES";
    else cout<<"NO";
    return 0;
}

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

#include<iostream>
using namespace std;
int main(){
  if(a<b)swap(a,b);
  if(b<c)swap(b,c);
  if(a<b)swap(a,b);
  if(c-b==b-a)cout<<"YES"<<endl;
  else cout<<"NO"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:6: error: 'a' was not declared in this scope
    4 |   if(a<b)swap(a,b);
      |      ^
a.cc:4:8: error: 'b' was not declared in this scope
    4 |   if(a<b)swap(a,b);
      |        ^
a.cc:5:6: error: 'b' was not declared in this scope
    5 |   if(b<c)swap(b,c);
      |      ^
a.cc:5:8: error: 'c' was not declared in this scope
    5 |   if(b<c)swap(b,c);
      |        ^
a.cc:6:6: error: 'a' was not declared in this scope
    6 |   if(a<b)swap(a,b);
      |      ^
a.cc:6:8: error: 'b' was not declared in this scope
    6 |   if(a<b)swap(a,b);
      |        ^
a.cc:7:6: error: 'c' was not declared in this scope
    7 |   if(c-b==b-a)cout<<"YES"<<endl;
      |      ^
a.cc:7:8: error: 'b' was not declared in this scope
    7 |   if(c-b==b-a)cout<<"YES"<<endl;
      |        ^
a.cc:7:13: error: 'a' was not declared in this scope
    7 |   if(c-b==b-a)cout<<"YES"<<endl;
      |             ^
Language: C++

#include<iostream>   
#include<string>
#include<vector>
using namespace std; 
 
int main()
{
	int c, a, b;
	cin >> a >> b >> c; 
	if ((b - a) == (c - b))
	{
		cout << "YES" << "\n";
	}
	else
	{
		cout << "NO" << "\n";
	}



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

#include <iostream>
using namespace std;
int main(){
int A,B,C;
cin >> A >> B >> C;
  if (A - B == B - C){
  cout << "YES" << endl;}
  else if {cout << "NO" << endl;}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:11: error: expected '(' before '{' token
    8 |   else if {cout << "NO" << endl;}
      |           ^
      |           (
Language: C++

#include<bits/stdc++.h>
using namespace std;
int a,b,c;
int main()
{
	scanf("%d%d%d",&a,&b,&c);
	if(b-a==c-b)
		puts("YES);
	else
		puts("NO");
	return 0;
}

Compiler output:
a.cc:8:22: warning: missing terminating " character
    8 |                 puts("YES);
      |                      ^
a.cc:8:22: error: missing terminating " character
    8 |                 puts("YES);
      |                      ^~~~~~
a.cc: In function 'int main()':
a.cc:9:9: error: expected primary-expression before 'else'
    9 |         else
      |         ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    cin>>a>>b>>c;
    if (b-a==c-b) cout<<"Yes";
    else cout<<"No";
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:10: error: 'a' was not declared in this scope
    5 |     cin>>a>>b>>c;
      |          ^
a.cc:5:13: error: 'b' was not declared in this scope
    5 |     cin>>a>>b>>c;
      |             ^
a.cc:5:16: error: 'c' was not declared in this scope
    5 |     cin>>a>>b>>c;
      |                ^
Language: C++


#include <cstdio>

int main(){
    int a,b,c;
    scanf("%d %d %d",&a,&b,&c);
    if(b − a == c − b){
        printf("YES\n");
    }else{
        printf("NO\n");
    }

    return 0;
}

Compiler output:
a.cc:7:10: error: extended character − is not valid in an identifier
    7 |     if(b − a == c − b){
      |          ^
a.cc:7:19: error: extended character − is not valid in an identifier
    7 |     if(b − a == c − b){
      |                   ^
a.cc: In function 'int main()':
a.cc:7:9: error: expected ')' before '\U00002212'
    7 |     if(b − a == c − b){
      |       ~ ^~
      |         )
Language: C++

#include <stdio.h>
int main(void)
{
	int a,b,c,d;
	scanf("%d%d%d",&a,&b,&c);
	if(a<b){
		if(b+b-a=c){
			printf("YES\n");
			return 0;
		}
	}if(a>b){
		if(b+b-c=a){
			printf("YES\n");
			return 0;
		}
	}
	printf("NO\n");
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:23: error: lvalue required as left operand of assignment
    7 |                 if(b+b-a=c){
      |                    ~~~^~
a.cc:12:23: error: lvalue required as left operand of assignment
   12 |                 if(b+b-c=a){
      |                    ~~~^~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int a[10000],b;
int main()
{
    cin>>a[1]>>a[2]>>a[3];
    sort(a+1,a+4);
    if(a[2]-a[1]==a[3]-a[2])
    {
        cout<<"YES"<<endl;
    }
    else
    {
        cout<<"NO"<<endl;
    }
}
    return 0;
}

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

#include<iostream>
#include<cstdio>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    if(b-a==c-b) cout<<"Yes";
    else cout<<"No";
    return 0
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:13: error: expected ';' before '}' token
   10 |     return 0
      |             ^
      |             ;
   11 | }
      | ~
Language: C++

#include <bits/stdc++.h>
#define REP(i,n) for(int i=0;i<(n);i++)
const int MOD=(int)1e9+7;
using namespace std;
int main(){
    int a,b,c;
    cin >> a >> b >> c;
    if(b-a = c-d) cout << "YES" << endl;
    else cout << "NO" << endl;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:8:16: error: 'd' was not declared in this scope
    8 |     if(b-a = c-d) cout << "YES" << endl;
      |                ^
Language: C++

#include <bits/stdc++.h>
#define REP(i,n) for(int i=0;i<(n);i++)
const int MOD=(int)1e9+7;
using namespace std;
int main(){
    int a,b,c;
    cin >> a >> b >> c;
    if(b-a == c-d) cout << "YES" << endl;
    else cout << "NO" << endl;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:8:17: error: 'd' was not declared in this scope
    8 |     if(b-a == c-d) cout << "YES" << endl;
      |                 ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
  int c,a,b;
int main()
{

  cin>>a>>b>>c;
  if (b-a=c-b)
    cout<<"YES"<<endl;
  else
    cout<<"NO";
   
}



Compiler output:
a.cc: In function 'int main()':
a.cc:8:8: error: lvalue required as left operand of assignment
    8 |   if (b-a=c-b)
      |       ~^~
Language: C++

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

int main(){
  int a,b,c;
  
  cin >> a >> b >> c;
  cout << (b-a == c-b) ? "YES" : "NO" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:39: error: invalid operands of types 'const char [3]' and '<unresolved overloaded function type>' to binary 'operator<<'
    8 |   cout << (b-a == c-b) ? "YES" : "NO" << endl;
      |                                  ~~~~~^~~~~~~
Language: C++

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

int main(){
  int a,b,c;
  
  cin >> a >> b >> c;
  cout << b-a = c-b ?"YES":"NO" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:33: error: invalid operands of types 'const char [3]' and '<unresolved overloaded function type>' to binary 'operator<<'
    8 |   cout << b-a = c-b ?"YES":"NO" << endl;
      |                            ~~~~~^~~~~~~
Language: C++

#include<iostream>
#include<algorithm>
#include<string>
#include<map>
#include<set>
#include<vector>
#include<string.h>
#include<math.h>
#include<stdio.h>
#include<queue>
#include<utility>
#include<cstdio>
#include<cstring>
#include<new>
#include<new.h>
#include<float.h>
#include<ctype.h>
#include<cfloat>
#include<cmath>
#include<cctype>
#include<errno.h>
#include<cerrno>
#include<memory>
#include<memory.h>
#include<assert.h>
#include<cassert>
#include<deque>
#include<sstream>
#define fo(i,w,n) for(int i=(int) w;i<(int) n;i++)
#define qui queue<int>
#define vit vector<int>
#define ll long long
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define prq priority_queue
#define pii pair<int,int>
#define mp make_pair
#define sz size()
#define em empty()
#define ct continue
#define ms multiset
#define all(a) (a).begin(),(a).end()
#define pf push_front
#define ppf pop_front()
using namespace std;
int main()
{
	int a,b,c;
	cin>>a>>b>>c;
	if(b-a==c-b)cout<<"YES";
	else cout<<"NO";
	return 0;
}

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

#include<algorithm>
#include<iostream>
using namespace std;
int a[5]={0,0,0,0,0};
int main()
{
	cin>>a[0]>>a[1]>>a[2];
	sort(a,a+3);
	if(a[1]-a[0]==a[2]-a[1]) cout<<"YES";
	else <<"NO";
    return 0; 
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:10:14: error: expected primary-expression before '<<' token
   10 |         else <<"NO";
      |              ^~
Language: C++

#include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
int main()
{
    int i[4];
    scanf("%d%d%d",&a[1],a[2],a[3]);
    sort(i+1,i+4);
    if(i[2]-i[1]==i[3]-i[2])
        cout<<"YES"<<endl;
    else
        cout<<"NO"<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: error: 'a' was not declared in this scope
    8 |     scanf("%d%d%d",&a[1],a[2],a[3]);
      |                     ^
Language: C++

#include<iostream>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;

        if(b−a==c−b){
          cout<<"YES"<<endl;}

        else
                cout<<"NO"endl;


    return 0;
}


Compiler output:
a.cc:8:12: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b){
      |            ^
a.cc:8:17: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b){
      |                 ^
a.cc: In function 'int main()':
a.cc:8:12: error: 'b\U00002212a' was not declared in this scope
    8 |         if(b−a==c−b){
      |            ^~~
a.cc:8:17: error: 'c\U00002212b' was not declared in this scope
    8 |         if(b−a==c−b){
      |                 ^~~
a.cc:12:23: error: unable to find string literal operator 'operator""endl' with 'const char [3]', 'long unsigned int' arguments
   12 |                 cout<<"NO"endl;
      |                       ^~~~~~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{int a,b,c;
cin>>a,b,c;
if((b-a)==(c-b))
cout<<"YES";
else 
cout<<"NO"}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:11: error: expected ';' before '}' token
    9 | cout<<"NO"}
      |           ^
      |           ;
Language: C++

#include<iostream>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    
        if(b−a==c−b)
          cout<<"YES"<<endl;
        
        else
                cout<<"NO"endl;
        
    
    return 0;
}


Compiler output:
a.cc:8:12: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b)
      |            ^
a.cc:8:17: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b)
      |                 ^
a.cc: In function 'int main()':
a.cc:8:12: error: 'b\U00002212a' was not declared in this scope
    8 |         if(b−a==c−b)
      |            ^~~
a.cc:8:17: error: 'c\U00002212b' was not declared in this scope
    8 |         if(b−a==c−b)
      |                 ^~~
a.cc:12:23: error: unable to find string literal operator 'operator""endl' with 'const char [3]', 'long unsigned int' arguments
   12 |                 cout<<"NO"endl;
      |                       ^~~~~~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    
        if(b−a==c−b)
        {
            cout<<"YES";
        }
        else{
                cout<<"NO";
        }
    
    return 0;
}


Compiler output:
a.cc:8:12: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b)
      |            ^
a.cc:8:17: error: extended character − is not valid in an identifier
    8 |         if(b−a==c−b)
      |                 ^
a.cc: In function 'int main()':
a.cc:8:12: error: 'b\U00002212a' was not declared in this scope
    8 |         if(b−a==c−b)
      |            ^~~
a.cc:8:17: error: 'c\U00002212b' was not declared in this scope
    8 |         if(b−a==c−b)
      |                 ^~~
Language: C++

#include<iostream>
using namespace std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    if(a>=1&&a>=100&&b>=1&&b<=100&&c>=1&&c<=100)
    {
        if(b−a==c−b)
        {
            cout<<"YES";
        }
        else{
                cout<<"NO";
        }
    }
    return 0;
}


Compiler output:
a.cc:9:12: error: extended character − is not valid in an identifier
    9 |         if(b−a==c−b)
      |            ^
a.cc:9:17: error: extended character − is not valid in an identifier
    9 |         if(b−a==c−b)
      |                 ^
a.cc: In function 'int main()':
a.cc:9:12: error: 'b\U00002212a' was not declared in this scope
    9 |         if(b−a==c−b)
      |            ^~~
a.cc:9:17: error: 'c\U00002212b' was not declared in this scope
    9 |         if(b−a==c−b)
      |                 ^~~
Language: C++

#include <iostream>

using namespace std;

int main()
{
    int a,b,c;
    cin>>a>>b>>c
    
    if((b-a)==(c-b))
       {
           
        cout<<"YES"<<endl;

    else cout<<"NO"<<endl;
    }

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:17: error: expected ';' before 'if'
    8 |     cin>>a>>b>>c
      |                 ^
      |                 ;
    9 | 
   10 |     if((b-a)==(c-b))
      |     ~~
Language: C++

#include<queue>
#include<cstdio>
#include<cstring>
#include<iostream>
#include<algorithm>
using namespace std;
int main()
{
	scanf("%d%d%d",&a,&b,&c);
	if (c-b==b-a) printf("YES");
	    else printf("NO");
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:25: error: 'a' was not declared in this scope
    9 |         scanf("%d%d%d",&a,&b,&c);
      |                         ^
a.cc:9:28: error: 'b' was not declared in this scope
    9 |         scanf("%d%d%d",&a,&b,&c);
      |                            ^
a.cc:9:31: error: 'c' was not declared in this scope
    9 |         scanf("%d%d%d",&a,&b,&c);
      |                               ^
Language: C++

#include<iostream>
#include<algorithm>
using namespace std;
long long a,b,c;
int main()
{
cin>>a>>b>>c;
if(b-a==c-b)cout<<"YES"<<endl;
else cout<"NO"<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:15: error: invalid operands of types 'const char [3]' and '<unresolved overloaded function type>' to binary 'operator<<'
    9 | else cout<"NO"<<endl;
      |           ~~~~^~~~~~
Language: C++

#include <iostream>
#include<math.h>


using namespace std;
int main(){
    int a,b,c;

    cin>>a>>b>>c;
    int r = sqrt((b-a)*(b-a));
    int p= sqrt((c-b)*(c-b));
    if(r==p){
        cout<<"YES"<<endl;
    }
    else if(r!=p){
        cout<<"NO"<<endl;
    }
    return 0;


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

#include<iostream>
#include<tgmath.h>
#include<math.h>

using namespace std;


int main(){
int a,b,c;

cin>>a>>b>>c;
int r = sqrt((b-a)*(b-a));
int p= sqrt((c-b)*(c-b));
if((r==p){
cout<<"Yes"<<endl;
}
else if(r!=p){
cout<<"NO"<<endl;
}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:10: error: expected ';' before '{' token
   14 | if((r==p){
      |          ^
      |          ;
a.cc:17:1: error: expected primary-expression before 'else'
   17 | else if(r!=p){
      | ^~~~
a.cc:16:2: error: expected ')' before 'else'
   16 | }
      |  ^
      |  )
   17 | else if(r!=p){
      | ~~~~
a.cc:14:3: note: to match this '('
   14 | if((r==p){
      |   ^
Language: C++

#include<iostream>
using namespace std;

int main(void){
  int a, b, c;
  cin >> a >> b >> c;
  if(b-a==c-b){
    cout << "YES" << endl;
  }else{
	coout << "NO" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:9: error: 'coout' was not declared in this scope
   10 |         coout << "NO" << endl;
      |         ^~~~~
Language: C++

#include < iostream >
using namespace std ;
  int main () {
    int a, b, c;
    cin >> a >> b >> c;
    cout << ( b-a == c-b ? "YES " : "NO" ) << endl ;
}

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

# include < iostream >
using namespace std ;
  int main () {
    int a, b, c;
    cin >> a >> b >> c;
    cout << ( b-a == c-b ? "YES " : "NO" ) << endl ;
}

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

#include<iostream>
using namespace std;
 
int main(void) {
  int a, b, c;
  cin >> a >> b >> c;
  
  if (b-a == c-b ) cout << endl;
}
#include<iostream>
using namespace std;

int main(void) {
  int a, b, c;
  cin >> a >> b >> c;
  
  if (b-a == c-b ) cout <<"YES" << endl;
  else cout << "NO" << endl;
}


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

#include <bits/stdc++.h>
using namespace std;
 
int main() {
int a, b, c;
cin >> a >> b >> c;
if(b-a = c-b){
cout << "YES" << endl;
}
else{
cout << "NO" << endl;
}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: lvalue required as left operand of assignment
    7 | if(b-a = c-b){
      |    ~^~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
int a, b, c;
cin >> a >> b >> c;
if(b-a = c-a){
cout << "YES" << endl;
}
else{
cout << "NO" << endl;
}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: lvalue required as left operand of assignment
    7 | if(b-a = c-a){
      |    ~^~
Language: C++

#include<bits/stdc++.h>
using namesapce std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    if (b-a==c-b) cout<<"YES"<<endl; 
     else cout<<"NO"<<endl;
    return 0;
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |     cin>>a>>b>>c;
      |     ^~~
      |     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:7:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |     if (b-a==c-b) cout<<"YES"<<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:7:32: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |     if (b-a==c-b) cout<<"YES"<<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)
      |     ^~~~
a.cc:8:11: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |      else cout<<"NO"<<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:8:23: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |      else cout<<"NO"<<endl;
      |                       ^~~~
      |                       std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include<bits/stdc++.h>
using namesapce std;
int main()
{
    int a,b,c;
    cin>>a>>b>>c;
    if (b-a==c-b) cout<<"YES"<<endl; 
     else cout<<"NO"<<endl;
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |     cin>>a>>b>>c;
      |     ^~~
      |     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:7:19: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |     if (b-a==c-b) cout<<"YES"<<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:7:32: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |     if (b-a==c-b) cout<<"YES"<<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)
      |     ^~~~
a.cc:8:11: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |      else cout<<"NO"<<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:8:23: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |      else cout<<"NO"<<endl;
      |                       ^~~~
      |                       std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

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

int main() {
    int a, b;
    cin >> a >> b;

    if(a==b && b==c){
        cout << "YES" << endl;
    }
    else cout << "NO" << endl;
    
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:19: error: 'c' was not declared in this scope
    9 |     if(a==b && b==c){
      |                   ^
Language: C++

#include <iostream>
using namespace std;


int main() {
	int a, b, c;
	cin >> a>>b>>c;
	int f = 2 * b - a - c;
	if (f == 0) { cout << "YES"; }
	else { cout << "NO; }
}

Compiler output:
a.cc:10:24: warning: missing terminating " character
   10 |         else { cout << "NO; }
      |                        ^
a.cc:10:24: error: missing terminating " character
   10 |         else { cout << "NO; }
      |                        ^~~~~~
a.cc: In function 'int main()':
a.cc:11:1: error: expected primary-expression before '}' token
   11 | }
      | ^
a.cc:11:2: error: expected '}' at end of input
   11 | }
      |  ^
a.cc:5:12: note: to match this '{'
    5 | int main() {
      |            ^
Language: C++

#include <iostream>
using namespace std;
int main() {
	int a, b, c;
	cin >> a >> b >> c;
  if(b-a==c-b){
	cout << YES << endl;
  }
  else{
   cout << NO << endl; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: 'YES' was not declared in this scope
    7 |         cout << YES << endl;
      |                 ^~~
a.cc:10:12: error: 'NO' was not declared in this scope
   10 |    cout << NO << endl;
      |            ^~
Language: Java

import java.util.Scanner;
public class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int a = sc.nextInt();
    int b = sc.nextInt();
    int c = sc.nextInt();
    if(b−a == c−b){
      System.out.print("YES");
    }else{
      System.out.print("NO")
    }
  }
}

Compiler output:
Main.java:8: error: illegal character: '\u2212'
    if(b?a == c?b){
        ^
Main.java:8: error: illegal character: '\u2212'
    if(b?a == c?b){
               ^
Main.java:8: error: not a statement
    if(b?a == c?b){
           ^
Main.java:8: error: not a statement
    if(b?a == c?b){
                ^
Main.java:8: error: ';' expected
    if(b?a == c?b){
                 ^
Main.java:11: error: ';' expected
      System.out.print("NO")
                            ^
Main.java:10: error: 'else' without 'if'
    }else{
     ^
7 errors
Language: C++

#include <iostream>

int main()
{
	int a,b,c;
	std::cin >> a >> b >> c;
	
	if(b-a == c-b)
	{
		std::cout << "YES" << endl;
	}
	else
	{
		std::cout << "NO" << endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:39: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   10 |                 std::cout << "YES" << 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)
      |     ^~~~
a.cc:14:38: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   14 |                 std::cout << "NO" << endl;
      |                                      ^~~~
      |                                      std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <iostream>

int main()
{
	int a,b,c;
	cin >> a >> b >> c;
	
	if(b-a == c-b)
	{
		std::cout << "YES" << endl;
	}
	else
	{
		std::cout << "NO" << endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |         cin >> a >> b >> c;
      |         ^~~
      |         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:10:39: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   10 |                 std::cout << "YES" << endl;
      |                                       ^~~~
      |                                       std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:14:38: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   14 |                 std::cout << "NO" << endl;
      |                                      ^~~~
      |                                      std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <iostream>

int main()
{
	int a,b,c;
	cin >> a >> b >> c;
	
	if(b-a == c-b)
	{
		cout << "YES" << endl;
	}
	else
	{
		cout << "NO" << endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |         cin >> a >> b >> c;
      |         ^~~
      |         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:10:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   10 |                 cout << "YES" << 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:10:34: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   10 |                 cout << "YES" << endl;
      |                                  ^~~~
      |                                  std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:14:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   14 |                 cout << "NO" << 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:14:33: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   14 |                 cout << "NO" << endl;
      |                                 ^~~~
      |                                 std::endl
/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(){
    int a, b, c, s, e, n, i, c=0;
    
    scanf("%d %d %d", &a, &b, &c);

    if(b-a == c-b) printf("YES");
    else           printf("NO");
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:30: error: redeclaration of 'int c'
    4 |     int a, b, c, s, e, n, i, c=0;
      |                              ^
a.cc:4:15: note: 'int c' previously declared here
    4 |     int a, b, c, s, e, n, i, c=0;
      |               ^
Language: C++

#include <stdio.h>

int main(){
    int a, b, c, s, e, n, i, c=0;
    
    scanf("%d %d %d", &a, &b, &c);

    if(b-a == c-b) printf("YES");
    else           printf("NO")
}




Compiler output:
a.cc: In function 'int main()':
a.cc:4:30: error: redeclaration of 'int c'
    4 |     int a, b, c, s, e, n, i, c=0;
      |                              ^
a.cc:4:15: note: 'int c' previously declared here
    4 |     int a, b, c, s, e, n, i, c=0;
      |               ^
a.cc:9:32: error: expected ';' before '}' token
    9 |     else           printf("NO")
      |                                ^
      |                                ;
   10 | }
      | ~
Language: C++

#include <iostream>
int main(void)
{
int a,b,c;
std::cin>>a>>b>>c;
std::cout<<((a-b==b-c)?”YES”:”NO”)<<std::endl;
return 0;
}

Compiler output:
a.cc:6:24: error: extended character ” is not valid in an identifier
    6 | std::cout<<((a-b==b-c)?”YES”:”NO”)<<std::endl;
      |                        ^
a.cc:6:24: error: extended character ” is not valid in an identifier
a.cc:6:30: error: extended character ” is not valid in an identifier
    6 | std::cout<<((a-b==b-c)?”YES”:”NO”)<<std::endl;
      |                              ^
a.cc:6:30: error: extended character ” is not valid in an identifier
a.cc: In function 'int main()':
a.cc:6:24: error: '\U0000201dYES\U0000201d' was not declared in this scope
    6 | std::cout<<((a-b==b-c)?”YES”:”NO”)<<std::endl;
      |                        ^~~~~
a.cc:6:30: error: '\U0000201dNO\U0000201d' was not declared in this scope
    6 | std::cout<<((a-b==b-c)?”YES”:”NO”)<<std::endl;
      |                              ^~~~
Language: C++

#include <iostream>
int main(void)
{
int a,b,c;
std::cin>>a>>b>>c;
std::cout<<(a-b==b-c?”YES”:”NO”)<<std::endl;
return 0;
}

Compiler output:
a.cc:6:22: error: extended character ” is not valid in an identifier
    6 | std::cout<<(a-b==b-c?”YES”:”NO”)<<std::endl;
      |                      ^
a.cc:6:22: error: extended character ” is not valid in an identifier
a.cc:6:28: error: extended character ” is not valid in an identifier
    6 | std::cout<<(a-b==b-c?”YES”:”NO”)<<std::endl;
      |                            ^
a.cc:6:28: error: extended character ” is not valid in an identifier
a.cc: In function 'int main()':
a.cc:6:22: error: '\U0000201dYES\U0000201d' was not declared in this scope
    6 | std::cout<<(a-b==b-c?”YES”:”NO”)<<std::endl;
      |                      ^~~~~
a.cc:6:28: error: '\U0000201dNO\U0000201d' was not declared in this scope
    6 | std::cout<<(a-b==b-c?”YES”:”NO”)<<std::endl;
      |                            ^~~~
Language: C

#include <stdio.h>
int main(void)
{
  int a,b,c;
  scanf("%d %d %d",&a,&b,&c);
  printf("%s\n", c-b==b-a?"YES","NO");
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:6:37: error: expected ':' before ')' token
    6 |   printf("%s\n", c-b==b-a?"YES","NO");
      |                                     ^
      |                                     :
Language: C++

int main(
int a,b,c;
cin>>a>>b>>c;
if(b-a==c-b){
     cout<<"Yes"<<endl;
}
else{
     cout<<"No"
}
    return0 ;


)

Compiler output:
a.cc:2:7: error: 'b' has not been declared
    2 | int a,b,c;
      |       ^
a.cc:2:9: error: 'c' has not been declared
    2 | int a,b,c;
      |         ^
a.cc:2:10: error: expected ')' before ';' token
    2 | int a,b,c;
      |          ^
      |          )
a.cc:1:9: note: to match this '('
    1 | int main(
      |         ^
a.cc:1:5: warning: second argument of 'int main(int, int, int)' should be 'char **' [-Wmain]
    1 | int main(
      |     ^~~~
a.cc:1:5: warning: third argument of 'int main(int, int, int)' should probably be 'char **' [-Wmain]
a.cc:3:1: error: 'cin' does not name a type
    3 | cin>>a>>b>>c;
      | ^~~
a.cc:4:1: error: expected unqualified-id before 'if'
    4 | if(b-a==c-b){
      | ^~
a.cc:7:1: error: expected unqualified-id before 'else'
    7 | else{
      | ^~~~
a.cc:10:5: error: 'return0' does not name a type
   10 |     return0 ;
      |     ^~~~~~~
a.cc:13:1: error: expected unqualified-id before ')' token
   13 | )
      | ^
Language: C++

#include <iostream>
using namespace std;

int main()
{
int a,b,c;

cin >> a >> b >> c;

if(b-a $$ c-b){
  cout << "YES" << endl;
  }else{
  cout << "NO" << endl;
  }

return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:7: error: expected ')' before '$$'
   10 | if(b-a $$ c-b){
      |   ~   ^~~
      |       )
Language: C++

#include <iostream>
using namespace std;

int main()
{
int a,b,c;

cin >> a >> b >> c;

if(b-a $$ c-b){
  cout << "YES" << endl;
  }else{
  cout << "NO" << endl;
  }

return 0
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:7: error: expected ')' before '$$'
   10 | if(b-a $$ c-b){
      |   ~   ^~~
      |       )
a.cc:16:9: error: expected ';' before '}' token
   16 | return 0
      |         ^
      |         ;
   17 | }
      | ~
Language: C++

#include <iostream>
using namespace std;

int main()
{
    int a, b, c;
    cin >> a >> b >> c;

    cout << (b - a == c - d ? "YES" : "NO") << endl;

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:27: error: 'd' was not declared in this scope
    9 |     cout << (b - a == c - d ? "YES" : "NO") << endl;
      |                           ^
Language: C++

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

using namespace std;

int main(){
    int a,b,c;
    cin>>a>>b>>c;

    if(b-a==c-b)cout<<"YES"<<endl;
    else count<<"NO"<<endl;

    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:15: error: invalid operands of types '<unresolved overloaded function type>' and 'const char [3]' to binary 'operator<<'
   13 |     else count<<"NO"<<endl;
      |          ~~~~~^~~~~~
Language: C++

#include <iostream>
using namespace std;
int main() {
  int x, y, z;
  cin >> x >> y;
  if(b - a == c - b) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:6: error: 'b' was not declared in this scope
    6 |   if(b - a == c - b) {
      |      ^
a.cc:6:10: error: 'a' was not declared in this scope
    6 |   if(b - a == c - b) {
      |          ^
a.cc:6:15: error: 'c' was not declared in this scope
    6 |   if(b - a == c - b) {
      |               ^
Language: C

#include<stdio.h>
 
int main(){
 
int a;
int b;
int c;
 
scanf("%d %d %d",&a,&b,&c);
 
if((b−a)==(c−b)){
printf("YES\n");
}else{
printf("NO\n");
}
 return 0;
}

Compiler output:
main.c: In function 'main':
main.c:11:6: error: stray '\342' in program
   11 | if((b<U+2212>a)==(c<U+2212>b)){
      |      ^~~~~~~~
main.c:11:6: error: expected ')' before 'a'
   11 | if((b−a)==(c−b)){
      |    ~ ^~
      |      )
main.c:11:13: error: stray '\342' in program
   11 | if((b<U+2212>a)==(c<U+2212>b)){
      |                    ^~~~~~~~
main.c:11:13: error: expected ')' before 'b'
   11 | if((b−a)==(c−b)){
      |           ~ ^~
      |             )
Language: C

#include<stdio.h>
 
int main(){
 
int a;
int b;
int c;
 
scanf("%d %d %d",&a,&b,&c);
 
if((b−a)!(c−b)){
printf("NO\n");
}else{
printf("YES\n");
}
 return 0;
}

Compiler output:
main.c: In function 'main':
main.c:11:6: error: stray '\342' in program
   11 | if((b<U+2212>a)!(c<U+2212>b)){
      |      ^~~~~~~~
main.c:11:6: error: expected ')' before 'a'
   11 | if((b−a)!(c−b)){
      |    ~ ^~
      |      )
main.c:11:9: error: expected ')' before '!' token
   11 | if((b−a)!(c−b)){
      |   ~     ^
      |         )
main.c:11:12: error: stray '\342' in program
   11 | if((b<U+2212>a)!(c<U+2212>b)){
      |                   ^~~~~~~~
Language: C

#include<stdio.h>
 
int main(){
 
int a,b,c;
 
scanf("%d %d %d",&a,&b,&c);
 
if((b−a)!(c−b)){
printf("NO\n");
}else{
printf("YES\n");
}
 return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:6: error: stray '\342' in program
    9 | if((b<U+2212>a)!(c<U+2212>b)){
      |      ^~~~~~~~
main.c:9:6: error: expected ')' before 'a'
    9 | if((b−a)!(c−b)){
      |    ~ ^~
      |      )
main.c:9:9: error: expected ')' before '!' token
    9 | if((b−a)!(c−b)){
      |   ~     ^
      |         )
main.c:9:12: error: stray '\342' in program
    9 | if((b<U+2212>a)!(c<U+2212>b)){
      |                   ^~~~~~~~
Language: C

#include<stdio.h>
 
int main(){
 
int a,b,c;
 
scanf("%d %d %d",&a,&b,&c);
 
if((b−a)!(c−b)){
printf("NO\n");
}else{
printf("YES\n");
}
 
}

Compiler output:
main.c: In function 'main':
main.c:9:6: error: stray '\342' in program
    9 | if((b<U+2212>a)!(c<U+2212>b)){
      |      ^~~~~~~~
main.c:9:6: error: expected ')' before 'a'
    9 | if((b−a)!(c−b)){
      |    ~ ^~
      |      )
main.c:9:9: error: expected ')' before '!' token
    9 | if((b−a)!(c−b)){
      |   ~     ^
      |         )
main.c:9:12: error: stray '\342' in program
    9 | if((b<U+2212>a)!(c<U+2212>b)){
      |                   ^~~~~~~~
Language: C

#include<stdio.h>
 
int main(){
 
int a,b,c;
 
scanf("%d %d %d",&a,&b,&c);
 
if(b−a!c−b){
printf("NO\n");
}else{
printf("YES\n");
}
 
}

Compiler output:
main.c: In function 'main':
main.c:9:5: error: stray '\342' in program
    9 | if(b<U+2212>a!c<U+2212>b){
      |     ^~~~~~~~
main.c:9:5: error: expected ')' before 'a'
    9 | if(b−a!c−b){
      |   ~ ^~
      |     )
main.c:9:9: error: stray '\342' in program
    9 | if(b<U+2212>a!c<U+2212>b){
      |                ^~~~~~~~
Language: C

#include<stdio.h>
 
int main(){
 
int a,b,c;
 
scanf("%d %d %d",&a,&b,&c);
 
if(b−a=c−b){
printf("YES\n");
}else{
printf("NO\n");
}
 
}

Compiler output:
main.c: In function 'main':
main.c:9:5: error: stray '\342' in program
    9 | if(b<U+2212>a=c<U+2212>b){
      |     ^~~~~~~~
main.c:9:5: error: expected ')' before 'a'
    9 | if(b−a=c−b){
      |   ~ ^~
      |     )
main.c:9:9: error: stray '\342' in program
    9 | if(b<U+2212>a=c<U+2212>b){
      |                ^~~~~~~~