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

#incluede<iostream>
using namespace std;
int main(){
int a;
cin>>a;
if(a==7,5,3)
cout<<"YES"<<endl;
else
cout<<"NO"<<endl;
return 0;
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #incluede; did you mean #include?
    1 | #incluede<iostream>
      |  ^~~~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:5:1: error: 'cin' was not declared in this scope
    5 | cin>>a;
      | ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #incluede<iostream>
a.cc:7:1: error: 'cout' was not declared in this scope
    7 | cout<<"YES"<<endl;
      | ^~~~
a.cc:7:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:7:14: error: 'endl' was not declared in this scope
    7 | cout<<"YES"<<endl;
      |              ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | #incluede<iostream>
a.cc:9:1: error: 'cout' was not declared in this scope
    9 | cout<<"NO"<<endl;
      | ^~~~
a.cc:9:1: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:9:13: error: 'endl' was not declared in this scope
    9 | cout<<"NO"<<endl;
      |             ^~~~
a.cc:9:13: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

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

#define int long long

int main(){
  int a;
  scanf("%d\n",&a);
  if(a==5||a==7||a==3){
    printf("YES\n");
  }else{
    printf("NO\n")
  }

  
  return 0;
}

Compiler output:
cc1plus: error: '::main' must return 'int'
a.cc: In function 'int main()':
a.cc:12:19: error: expected ';' before '}' token
   12 |     printf("NO\n")
      |                   ^
      |                   ;
   13 |   }
      |   ~
Language: C++

#include <iostream>
#include <stdio.h>
#include <string>
#include <cstdlib>
#include <cmath>
#include <cstring>
#include <math.h>
#include <vector>
#include <algorithm>

using namespace std;

typedef unsigned long long ull;
typedef long long ll;

int main(){
	int n;
	cin >> n;
	if(n==3 || n==5 || n==7) cout "YES" << endl;
	else cout << "NO" << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:19:38: error: expected ';' before string constant
   19 |         if(n==3 || n==5 || n==7) cout "YES" << endl;
      |                                      ^~~~~~
      |                                      ;
Language: C++

#include<stdio.h>
#include<stdlib.h>
#include<iostream>
#include<string>
#include<algorithm>
#include<vector> 
#include<limits>
#include<numeric>
#include<type_traits>
#include<math.h>
using namespace std;
typedef long long ll;

#define rep(i, n) for(int i = 0; i < (int)(n); i++)
#define repi(i,a,b) for(int i = (int)(a); i < (int)(b); i++)
#define in(x) cin >> x
#define out(str) cout << str << endl

template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }

int X;

int main(){
    cin>>X:
    if(X==3||X==5||X==7){
        out("YES");
    }
    else{
        out("NO");
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:11: error: expected ';' before ':' token
   25 |     cin>>X:
      |           ^
      |           ;
a.cc:29:5: error: 'else' without a previous 'if'
   29 |     else{
      |     ^~~~
Language: C++

X = int(input())
if X == 7 or X == 5 or X == 3:
    print('YES')
else:
    print('NO')


Compiler output:
a.cc:3:11: warning: multi-character character constant [-Wmultichar]
    3 |     print('YES')
      |           ^~~~~
a.cc:5:11: warning: multi-character character constant [-Wmultichar]
    5 |     print('NO')
      |           ^~~~
a.cc:1:1: error: 'X' does not name a type
    1 | X = int(input())
      | ^
Language: C++

#include<iostream>

using namespace std;
int main()
{
	int n,;
	cin >> n;
	if(n == 3 || n == 5 || n == 7)
		cout << "YES" << endl;
	else
		cout << "NO" << endl;
	
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:15: error: expected unqualified-id before ';' token
    6 |         int n,;
      |               ^
Language: C++

#include <cstdio>
#include <iostream>
#include <vector>
#include <set>
#include <cstring>
#include <string>
#include <map>
#include <cmath>
#include <ctime>
#include <algorithm>
#include <bitset>
#include <queue>
#include <sstream>
using namespace std;
#define mp make_pair
#define pb push_back
#define re return
#define fi first
#define se second
typedef vector<int> vi;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> pii;
typedef vector<pii> vpii;
typedef vector<string> vs;
typedef vector<vi> vvi;zzz
int main() {
    //freopen("input.txt","r",stdin);
	//freopen("output.txt","w",stdout);
	int a;
	cin>>a;
	if(a==7 || a==5 || a==3)cout<<"YES"<<endl;
	else cout<<NO"<<endl;
    return 0;
}

Compiler output:
a.cc:33:22: warning: missing terminating " character
   33 |         else cout<<NO"<<endl;
      |                      ^
a.cc:33:22: error: missing terminating " character
   33 |         else cout<<NO"<<endl;
      |                      ^~~~~~~~
a.cc:26:24: error: 'zzz' does not name a type
   26 | typedef vector<vi> vvi;zzz
      |                        ^~~
Language: C++

#include <iostream>
using namespace std;
int main(void){
    
    
}

#include<iostream>
#include<string>
#include<cstdio>
#include<algorithm>
#include<cstdlib>
#include<cmath>
#include<vector>
#include<utility>
#include<queue>
#include<stack>
#include<set>
#include<map>
#include<unordered_set>
#include<bitset>
using namespace std;
//#define MODE 1
#ifdef MODE
#define DEB(X) cout<< #X <<": "<<X<<" ";
#define ARDEB(i,X) cout<< #X <<"["<<i<<"]: "<<X[i]<<" ";
#define END cout<<endl;
#else
#define DEB(X) {}
#define ARDEB(i,X) {}
#define END {}
#endif
typedef long long int ll;
int main(){
    
    int n;
    cin>>n;
    if(n==7 || n==5 || n==3){
        cout<<"YES"<<endl;
    }
    else cout<<"NO"<<endl;
    
    

}





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

#include<bits/stdc++.h
using namespace std;
int X;
int main(){
    cin>>X;
    if(X==3||X==5||X==7){
        cout<<"YES"<<endl;
    }else cout<<"NO"<<endl;
    return 0;
}

Compiler output:
a.cc:1:23: error: missing terminating > character
    1 | #include<bits/stdc++.h
      |                       ^
Language: C++

#include <bits/stdc++.h>
#define rep(i, a, b) for(int i = int(a); i < int(b); i++)
#define rer(i, a, b) for(int i = int(a) - 1; i >= int(b); i--)

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

const ll MOD=1000000007;

int main() {
    ios::sync_with_stdio(false);
    cin.tie(0);
    int N;
    cin>> N;
    if (N==3||N==5||N==7){
        cout << "YES"<<"\n";
    }
    ele{
    cout << "NO"<<"\n";
    }
}



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

#include <iostream>
#include <string>
#include <algorithm>
#include <cstdio>
#include <vector>
#include <queue>
#include <set>
#include <map>
#include <numeric>
#include <cmath>

using namespace std;

typedef long long int ll;

#define all(x) x.begin(),x.end()

const ll mod = 1e9+7;
const ll INF = 1e9;
const ll MAXN = 1e9;

int main()
{
  int x;
  cin >> x;
  if(x==3||x==5||x==7) cout << "YES" << endl;
  else cout << "NO" << endl

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:27:28: error: expected ';' before 'return'
   27 |   else cout << "NO" << endl
      |                            ^
      |                            ;
   28 | 
   29 |   return 0;
      |   ~~~~~~
Language: C++

#include<bits/stdc++.h>
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define REP(i, n) for (int i = 0; i < (n); ++i)
#define int long long
#define vec(a,n) vector<int> (a)((n))
#define Vec(a,n) vector<string> (a)((n))
#define P pair<int,int>
#define PQ(n) priority_queue<P,vector<P>,greater<P>> (n)
#define pq(n) priority_queue<int> (n)
using namespace std;

signed main(){

    int a,b;
    cin >> a ;
    if(a == 3 || a == 5 || a == 7){
        cout << "YES";
    }
    else{
        cout << "NO"
    }
    return 0;
}


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

#define _CRT_SECURE_NO_WARNINGS

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

/* define *************************/
//for
#define REP(i,n) for(int i=0,i##_len=(int)(n);i<i##_len;i++)
#define REPS(i,n) for(int i=1,i##_len=(int)(n);i<=i##_len;i++)
#define RREP(i,n) for(int i=(int)(n)-1;i>=0;i--)
#define RREPS(i,n) for(int i=(int)(n);i>0;i--)
#define FOR(i,s,n) for(int i=(int)(s),i##_len=(int)(n);i<i##_len;i++)
#define RFOR(i,s,n) for(int i=(int)(s)-1,i##_len=(int)(n);i>=i##_len;i--)

//printf
#define PRINTD(d) printf("%d\n",(d))
#define PRINTL(d) printf("%lld\n",(d))

//memset
#define m0(s) memset(s,0,sizeof(s))
#define ml(s) memset(s,63,sizeof(s))
#define fill(s,c) memset(s,c,sizeof(s))

#define INF 1e9
#define MOD 1000000007

typedef long long ll;
typedef unsigned long long ull;

int p[100000];
int y[100000];
int z[100000];
int ans[100000];

int diff[4][2] = {
	{ 0, -1 },
	{ -1, 0 },
	{ 1, 0 },
	{ 0, 1 },
};

int Min(int a, int b) {
	return (a)<(b) ? (a) : (b);
}
int  Max(int  a, int  b) {
	return (a) > (b) ? (a) : (b);
}
void Swap(int *a, int *b) {
	int tmp = *a;
	*a = *b;
	*b = tmp;
}void hSwap(int x[], int i, int j)
{
	int temp;

	temp = x[i];
	x[i] = x[j];
	x[j] = temp;
}

void ShowData(int x[], int left, int right)
{
	int i;
	for (i = left; i <= right; i++)printf("%d  ", x[i]);
	printf("\n");
}
void QSort(int x[], int left, int right, int n) {
	int i, j;	//左端,右端
	int pivot;	//軸

	i = left;
	j = right;
	pivot = x[(left + right) / 2];

	while (1) {
		if (n > 0) {				//n>0なら昇順、n<=0なら降順
			while ((x[i] < pivot) && (i <= right))i++;	//軸値より大きい要素
			while ((pivot < x[j]) && (i <= right))j--;	//軸値より小さい要素
		}
		else {
			while ((x[i] > pivot) && (i <= right))i++;	//軸値より小さい要素
			while ((pivot > x[j]) && (i <= right))j--;	//軸値より大きい要素
		}
		if (i >= j)	break;
		hSwap(x, i, j);
		i++; j--;
	}
	//ShowData(x, left, right);

	if (left < i - 1)QSort(x, left, i - 1, n);
	if (j + 1 <  right)QSort(x, j + 1, right, n);
}

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

int main() {
	int n;
	scanf("%d%d", &n,);
	if (n == 3 || n == 5 || n == 7) {
		puts("YES");
	}
	else {
		puts("NO");
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:107:26: error: expected primary-expression before ')' token
  107 |         scanf("%d%d", &n,);
      |                          ^
Language: C++

#include <iostream>
#include <string>
#include <algorithm>
#include <functional>
#include <vector>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <cstdio>
#include <cmath>
#include <tuple>
#include <cassert>
#define rep(i, n) for(i = 0; i < n; i++)
//#define int long long

signed main() {
	int x;
	cin >> x;
	if (x == 3 || x == 5 || x == 7) cout << "YES" << endl;
	else cout << "NO" << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:19:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   19 |         cin >> x;
      |         ^~~
      |         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:20:41: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   20 |         if (x == 3 || x == 5 || x == 7) 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:20:58: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   20 |         if (x == 3 || x == 5 || x == 7) 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:21:14: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   21 |         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:21:30: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   21 |         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 <iostream>
#include <string>
#include <algorithm>
#include <iomanip>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <functional>
#include <math.h>

using namespace std;
const int mod = 1000000007;
const double pi = 3.141592653589793238462643382795028841971;

int main() {
	int n;
	ciin >> n;
	if (n == 7 || n == 5 || n == 3) cout << "YES" << endl;
	else cout << "NO" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:9: error: 'ciin' was not declared in this scope
   18 |         ciin >> n;
      |         ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rrep(i, n) for (int i = 1; i < (int)(n+1); i++)
const long long INF = 1LL << 60;
int main(){
    string N;
    cin>>N;
    int a=N.size();
    ll S;
    rep(i,a){
        S+=N[a-i-1]*pow(10,i);
    }
    ll ans=10000;
    for(int i=0; i<8; i++){
        if(abs(S[i]*100+S[i+1]*10+S[i+2])<ans){
            ans=S[i]*100+S[i+1]*10+S[i+2];
        }
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:17: error: invalid types 'll {aka long long int}[int]' for array subscript
   18 |         if(abs(S[i]*100+S[i+1]*10+S[i+2])<ans){
      |                 ^
a.cc:18:26: error: invalid types 'll {aka long long int}[int]' for array subscript
   18 |         if(abs(S[i]*100+S[i+1]*10+S[i+2])<ans){
      |                          ^
a.cc:18:36: error: invalid types 'll {aka long long int}[int]' for array subscript
   18 |         if(abs(S[i]*100+S[i+1]*10+S[i+2])<ans){
      |                                    ^
a.cc:19:18: error: invalid types 'll {aka long long int}[int]' for array subscript
   19 |             ans=S[i]*100+S[i+1]*10+S[i+2];
      |                  ^
a.cc:19:27: error: invalid types 'll {aka long long int}[int]' for array subscript
   19 |             ans=S[i]*100+S[i+1]*10+S[i+2];
      |                           ^
a.cc:19:37: error: invalid types 'll {aka long long int}[int]' for array subscript
   19 |             ans=S[i]*100+S[i+1]*10+S[i+2];
      |                                     ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
using ll=long long;
int main() {
  string a;
  cin>>a;
  ll b=1000;
  for(ll i=0;i<7;i++){
    ll c,d,e;
    c=vec.at(i)-'0';
    d=vec.at(i+1)-'0';
    e=vec.at(i+2)-'0';
    b=min(b,abs(100*c+10*d+e-743));
  }
  cout<<b<<endl;
  return 0;
}
    
    
  


Compiler output:
a.cc: In function 'int main()':
a.cc:10:7: error: 'vec' was not declared in this scope
   10 |     c=vec.at(i)-'0';
      |       ^~~
Language: C++

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

int main()
{
  string s;
  cin >> s;
  int ans = 10000;
  for(int i=0; i<s.size()-3; i++)
  {
    string subs = substr(i, 3);
    int a = atoi(subs);
    ans = min(ans, abs(x - a));
  }
  
  cout << ans << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:19: error: 'substr' was not declared in this scope; did you mean 'subs'?
   12 |     string subs = substr(i, 3);
      |                   ^~~~~~
      |                   subs
a.cc:13:18: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'const char*'
   13 |     int a = atoi(subs);
      |                  ^~~~
      |                  |
      |                  std::string {aka std::__cxx11::basic_string<char>}
In file included from /usr/include/c++/14/cstdlib:79,
                 from /usr/include/c++/14/ext/string_conversions.h:43,
                 from /usr/include/c++/14/bits/basic_string.h:4154,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/stdlib.h:105:30: note:   initializing argument 1 of 'int atoi(const char*)'
  105 | extern int atoi (const char *__nptr)
      |                  ~~~~~~~~~~~~^~~~~~
a.cc:14:24: error: 'x' was not declared in this scope
   14 |     ans = min(ans, abs(x - a));
      |                        ^
Language: C++

#include <iostream>
#include <algorithm>
#include <vector>
#include <cmath>
using namespace std;
const int MOD = 1e9+7;
using ll = long long;
using vi = vector<int>;
#define rep(i, n) for (int i = 0; i < n; i++)
#define ALL(x) x.begin(), x.end()
int main() {
  ll a;
  cin >> a;
  int ans = 999;
  while(a>99){
    ans = min(ans,abs(753-a%1000));
    a /= 10;
  }
  cout << ans;
} 

Compiler output:
a.cc: In function 'int main()':
a.cc:16:14: error: no matching function for call to 'min(int&, long long int)'
   16 |     ans = min(ans,abs(753-a%1000));
      |           ~~~^~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/string:51,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   template argument deduction/substitution failed:
a.cc:16:14: note:   deduced conflicting types for parameter 'const _Tp' ('int' and 'long long int')
   16 |     ans = min(ans,abs(753-a%1000));
      |           ~~~^~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281:5: note:   candidate expects 3 arguments, 2 provided
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   candidate expects 1 argument, 2 provided
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   template argument deduction/substitution failed:
a.cc:16:14: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
   16 |     ans = min(ans,abs(753-a%1000));
      |           ~~~^~~~~~~~~~~~~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
#define INF 1e9

int main(){
  string S; cin>>S;
  int ans=INF;
  rep(i,S.length()-2){
    int a[3];
    int X;
    rep(j,3){
      a[j]=S[i+j]-'0';
      X+=pow(10,2-j)*a[j];
    }
    ans=min(ans,abs(X-753));
  }
  cout<<ans<<endl;
  return 0;
}
    

Compiler output:
a.cc: In function 'int main()':
a.cc:8:7: error: 'i' was not declared in this scope
    8 |   rep(i,S.length()-2){
      |       ^
a.cc:8:3: error: 'rep' was not declared in this scope
    8 |   rep(i,S.length()-2){
      |   ^~~
Language: C++

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

int main()
{
  string S;
  cin >> S;
  const int chk=753;
  int ans=754;
  for(int i=0; i<int(S.size())-2; i++)
  {
    if(ans>=chk-int(S.at(i))*100+int(S.at(i+1))+int(S.at(i+2)))
    {
      ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
    }
  }
  cout << ans << endl;                                               
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:32: error: expected primary-expression before 'int'
   14 |       ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
      |                                ^~~
Language: C++

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

int main()
{
  string S;
  cin >> S;
  const int chk=753;
  int ans=754;
  for(int i=0; i<int(S.size())-2; i++)
  {
    if(ans>=chk-int(S.at(i))*100+int(S.at(i+1))+int(S.at(i+2))))
    {
      ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
    }
  }
  cout << ans << endl;                                               
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:64: error: expected primary-expression before ')' token
   12 |     if(ans>=chk-int(S.at(i))*100+int(S.at(i+1))+int(S.at(i+2))))
      |                                                                ^
Language: C++

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

int main()
{
  string S;
  cin >> S;
  const int chk=753;
  int ans=754;
  for(int i=0; i<S.size()-2; i++)
  {
    if(ans>=chk-int(S.at(i))*100+int(S.at(i+1))+int(S.at(i+2)))))
    {
      ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
    }
  }
  cout << ans << endl;                                               
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:64: error: expected primary-expression before ')' token
   12 |     if(ans>=chk-int(S.at(i))*100+int(S.at(i+1))+int(S.at(i+2)))))
      |                                                                ^
Language: C++

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

int main()
{
  string S;
  cin >> S;
  const int chk=753;
  int ans=754;
  for(int i=0; i<S.size()-2; i++)
  {
    if(ans>=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2))))
    {
      ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
    }
  }
  cout << ans << endl;                                               
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:32: error: expected primary-expression before 'int'
   14 |       ans=chk-int(S.at(i))*100+int(S.at(i+1)+int(S.at(i+2);
      |                                ^~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for(int i = 0; i < int(n); i++);
int main() {
  string S;
  cin >> S;
  int ans = 753;
  rep(i, S.size() - 2) {
    int num = S.at(i) * 100 + S.at(i + 1) * 10 + S.at(i + 2);
    int sub;
    if(num > 753) {
      sub = num - 753;
    }
    else {
      sub = 753 - num;
    }
    if(ans > sub) {
      ans = sub;
    }
  }
  cout << ans << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:20: error: 'i' was not declared in this scope
    9 |     int num = S.at(i) * 100 + S.at(i + 1) * 10 + S.at(i + 2);
      |                    ^
Language: C++

#include <bits/stdc++.h>
uisng namespace std;
#define rep(i, n) for(int i = 0; i < int(n); i++);
int main() {
  string S;
  cin >> S;
  int ans = 753;
  rep(i, S.size() - 2) {
    int num = S.at(i) * 100 + S.at(i + 1) * 10 + S.at(i + 2);
    int sub;
    if(num > 753) {
      sub = num - 753;
    }
    else {
      sub = 753 - num;
    }
    if(ans > sub) {
      ans = sub;
    }
  }
  cout << ans << endl;
}

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:5:3: error: 'string' was not declared in this scope
    5 |   string S;
      |   ^~~~~~
a.cc:5:3: note: suggested alternatives:
In file included from /usr/include/c++/14/string:41,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:6:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |   cin >> S;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:6:10: error: 'S' was not declared in this scope
    6 |   cin >> S;
      |          ^
a.cc:9:20: error: 'i' was not declared in this scope
    9 |     int num = S.at(i) * 100 + S.at(i + 1) * 10 + S.at(i + 2);
      |                    ^
a.cc:21:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   21 |   cout << ans << 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:21:18: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   21 |   cout << ans << 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<bits/stdc++.h>
int main()
{
string s;
  cin >> s;
  int min,i,temp,k;
  min=753;
  
  for(i=0;i<s.size()-2;++i)
  {
  temp=int(s.at(i)-'0')*100+int(s.at(i+1)-'0')*10+int(s.at(i+2)-'0');
  if(temp<753) k=753-temp;
  else k=temp-753;
  if(k<min) min=k;
  }

   cout << min;
  
return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:1: error: 'string' was not declared in this scope
    4 | string s;
      | ^~~~~~
a.cc:4:1: note: suggested alternatives:
In file included from /usr/include/c++/14/string:41,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:5:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |   cin >> s;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:5:10: error: 's' was not declared in this scope
    5 |   cin >> s;
      |          ^
a.cc:17:4: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   17 |    cout << min;
      |    ^~~~
      |    std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

/*
      author  : nishi5451
      created : 14.08.2020 22:59:03
*/

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

const int INF = 2e9;

int main(){
    string s;
    cin >> s;
    int ans = INF;
    for(int i=0; i<int(s.size())-3; i++){
        string t = substr(i,3);
        ans = min(ans,abs(atoi(t.c_str())-753));
    }
    cout << ans << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:20: error: 'substr' was not declared in this scope; did you mean 'strstr'?
   18 |         string t = substr(i,3);
      |                    ^~~~~~
      |                    strstr
Language: C++

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

using namespace std;

void b_754(void) {
	string s;
	cin >> s;
	int min = 753;

	for (int i = 0; i < s.size() - 2; i++) {
		int num =stoi( s.substr(i, 3));
		int dif = abs(753 - num);

		if (min > dif) min = dif;
	}

	cout << min << endl;
}

void main()
{
    b_754();
}

Compiler output:
a.cc:23:1: error: '::main' must return 'int'
   23 | void main()
      | ^~~~
Language: C++

#include <iostream>
#include <string>
#include <cmath>
#include <sstream>
using namespace std;
 
int main() {
  string s, c;
  cin >> s;
  
  int l = s.size(), ans = 0, maxAns = 0;
  
  for(int i = 0; i < l - 2; ++i)
  {
    c = s.substr(s.begin(), 3);
    stringstream str(c);
    str >> ans;
    ans = abs(ans - 753);
    if(ans > maxAns)
      maxAns = ans;
  }
  cout << maxAns;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:25: error: cannot convert 'std::__cxx11::basic_string<char>::iterator' to 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'}
   15 |     c = s.substr(s.begin(), 3);
      |                  ~~~~~~~^~
      |                         |
      |                         std::__cxx11::basic_string<char>::iterator
In file included from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/basic_string.h:3208:24: note:   initializing argument 1 of 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::substr(size_type, size_type) const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
 3208 |       substr(size_type __pos = 0, size_type __n = npos) const
      |              ~~~~~~~~~~^~~~~~~~~
Language: C++

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

int main() {
  string s, c;
  cin >> s;
  
  int l = s.size(), ans = 0, maxAns = 0;
  
  for(int i = 0; i < l - 2; ++i)
  {
    c = s.substr(s.begin(), 3);
    stringstream str(c);
    str >> ans;
    ans = abs(ans - 753);
    if(ans > maxAns)
      maxAns = ans;
  }
  cout 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:25: error: cannot convert 'std::__cxx11::basic_string<char>::iterator' to 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'}
   15 |     c = s.substr(s.begin(), 3);
      |                  ~~~~~~~^~
      |                         |
      |                         std::__cxx11::basic_string<char>::iterator
In file included from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/basic_string.h:3208:24: note:   initializing argument 1 of 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc> std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::substr(size_type, size_type) const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
 3208 |       substr(size_type __pos = 0, size_type __n = npos) const
      |              ~~~~~~~~~~^~~~~~~~~
a.cc:22:7: error: expected ';' before '}' token
   22 |   cout
      |       ^
      |       ;
   23 | }
      | ~
Language: Java

import java.util.*;

public class Main {
	public static void main(String[] args) throws Exception{
		Scanner scn = new Scanner(System.in);
		String s = scn.next();
      int len = s.length(); 
      int ans = 753;
      int x = 0;
      int xx = 753;
      String list[] = s.split("");    
		int[] a = new int[len];
		for(int i=0; i<len; ++i){
			a[i] = Integer.parseInt(list[i]);
		}
      for(int i=0; i<len-2; ++i){
        int x = a[i]*100 + a[i+1]*10 + a[i+2];
        xx = Math.abs(753-x);
        if(ans>xx){
          ans = xx;
        }
      }
      System.out.println(ans);
	}
}


Compiler output:
Main.java:17: error: variable x is already defined in method main(String[])
        int x = a[i]*100 + a[i+1]*10 + a[i+2];
            ^
1 error
Language: Java

import java.util.*;

public class Main {
	public static void main(String[] args) throws Exception{
		Scanner scn = new Scanner(System.in);
		int s = scn.nextInt();
      int len = String.valueOf(len).length(); 
      int ans = 0;
      int list[] = s.split("");    
		int[] a = new int[n];
		for(int i=0; i<len; ++i){
			a[i] = list[i];
		}
	}
}

Compiler output:
Main.java:9: error: int cannot be dereferenced
      int list[] = s.split("");    
                    ^
Main.java:10: error: cannot find symbol
		int[] a = new int[n];
		                  ^
  symbol:   variable n
  location: class Main
2 errors
Language: C++

#include<stdio.h>
#include<iostream>
#include<vector>
#include<math.h>
#include<queue>
#include<map>
#include<algorithm>
#include<string.h>
#include<functional>
#include<limits.h>
#include<stdlib.h>
#include<string>
#include<unordered_map>
#include <iomanip>
using namespace std;
 
#define intmax INT_MAX
#define lmax LONG_MAX
#define uintmax UINT_MAX
#define ulmax ULONG_MAX
#define llmax LLONG_MAX
#define ll long long
#define rep(i,a,N) for((i)=(a);(i)<(N);(i)++)
#define rrp(i,N,a) for((i)=(N)-1;(i)>=(a);(i)--)
#define llfor ll i,j,k
#define sc(a) cin>>a
#define pr(a) cout<<a<<endl
#define pY puts("YES")
#define pN puts("NO")
#define py puts("Yes")
#define pn puts("No")
#define pnn printf("\n")
#define sort(a) sort(a.begin(),a.end())
#define push(a,b) (a).push_back(b)
#define llvec vector<vector<ll>>
#define charvec vector<vector<char>>
#define sizeoof(a,b) (a,vector<ll>(b))
#define llpvec vector<pair<ll,ll>>
/*繰り上げ除算*/ll cei(ll x,ll y){ll ans=x/y;if(x%y!=0)ans++;return ans;}
/*最大公約数*/ll gcd(ll x,ll y){return y?gcd(y,x%y):x;}
/*最小公倍数*/ll lcm(ll x,ll y){return x/gcd(x,y)*y;}
/*n乗*/ll llpow(ll x,ll n){ll i,ans=1;rep(i,0,n)ans*=x;return ans;}
/*階乗*/ll fact(ll x){ll i,ans=1;rep(i,0,x)ans*=(x-i);return ans;}
/*nCr*/ll ncr(ll n,ll r){return fact(n)/fact(r)/fact(n-r);}
/*nPr*/ll npr(ll n,ll r){return fact(n)/fact(n-r);}
/*primejudge*/bool prime(ll a){if(a<=1)return false;ll i;for(i=2;i*i<=a;i++){if(a%i==0)return false;}return true;}
ll ans=0;llfor;///////////////////////////////////////////////////////////
int sft(ll N){
  int x=1;
  string S=N;
  int K=S.size();
  for(int i=0;i<K;i++){
    if(S[i]!='3' || S[i]!='5' || S[i]!='7') x*=0;
  }
  return x;}

int main(){
  vector<ll> X(1000000040);
  X.at(0)=0;
  for(ll i=1;i<1000000010;i++){
    if(sft(i)==1) X.at(i)=X.at(i-1)+1;
  }
  ll N;
  cin>>N;
  cout<<X.at(N);
return 0;}


Compiler output:
a.cc: In function 'int sft(long long int)':
a.cc:50:12: error: conversion from 'long long int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   50 |   string S=N;
      |            ^
Language: C++

#include<stdio.h>
#include<iostream>
#include<vector>
#include<math.h>
#include<queue>
#include<map>
#include<algorithm>
#include<string.h>
#include<functional>
#include<limits.h>
#include<stdlib.h>
#include<string>
#include<unordered_map>
#include <iomanip>
using namespace std;
 
#define intmax INT_MAX
#define lmax LONG_MAX
#define uintmax UINT_MAX
#define ulmax ULONG_MAX
#define llmax LLONG_MAX
#define ll long long
#define rep(i,a,N) for((i)=(a);(i)<(N);(i)++)
#define rrp(i,N,a) for((i)=(N)-1;(i)>=(a);(i)--)
#define llfor ll i,j,k
#define sc(a) cin>>a
#define pr(a) cout<<a<<endl
#define pY puts("YES")
#define pN puts("NO")
#define py puts("Yes")
#define pn puts("No")
#define pnn printf("\n")
#define sort(a) sort(a.begin(),a.end())
#define push(a,b) (a).push_back(b)
#define llvec vector<vector<ll>>
#define charvec vector<vector<char>>
#define sizeoof(a,b) (a,vector<ll>(b))
#define llpvec vector<pair<ll,ll>>
/*繰り上げ除算*/ll cei(ll x,ll y){ll ans=x/y;if(x%y!=0)ans++;return ans;}
/*最大公約数*/ll gcd(ll x,ll y){return y?gcd(y,x%y):x;}
/*最小公倍数*/ll lcm(ll x,ll y){return x/gcd(x,y)*y;}
/*n乗*/ll llpow(ll x,ll n){ll i,ans=1;rep(i,0,n)ans*=x;return ans;}
/*階乗*/ll fact(ll x){ll i,ans=1;rep(i,0,x)ans*=(x-i);return ans;}
/*nCr*/ll ncr(ll n,ll r){return fact(n)/fact(r)/fact(n-r);}
/*nPr*/ll npr(ll n,ll r){return fact(n)/fact(n-r);}
/*primejudge*/bool prime(ll a){if(a<=1)return false;ll i;for(i=2;i*i<=a;i++){if(a%i==0)return false;}return true;}
ll ans=0;llfor;///////////////////////////////////////////////////////////
int main(){
  string S;
  cin>>S;
  int N=S.size();
  int m=1000;
  for(int i=0;i<=N-2;i++){
    string T=S[i]+S[i+1]+S[i+2];
    int K=stoi(T);
    m=min(m,abs(K-753));
  }
  cout<<m;
return 0;}


Compiler output:
a.cc: In function 'int main()':
a.cc:54:25: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   54 |     string T=S[i]+S[i+1]+S[i+2];
Language: C++

#include<stdio.h>
#include<iostream>
#include<vector>
#include<math.h>
#include<queue>
#include<map>
#include<algorithm>
#include<string.h>
#include<functional>
#include<limits.h>
#include<stdlib.h>
#include<string>
#include<unordered_map>
#include <iomanip>
using namespace std;
 
#define intmax INT_MAX
#define lmax LONG_MAX
#define uintmax UINT_MAX
#define ulmax ULONG_MAX
#define llmax LLONG_MAX
#define ll long long
#define rep(i,a,N) for((i)=(a);(i)<(N);(i)++)
#define rrp(i,N,a) for((i)=(N)-1;(i)>=(a);(i)--)
#define llfor ll i,j,k
#define sc(a) cin>>a
#define pr(a) cout<<a<<endl
#define pY puts("YES")
#define pN puts("NO")
#define py puts("Yes")
#define pn puts("No")
#define pnn printf("\n")
#define sort(a) sort(a.begin(),a.end())
#define push(a,b) (a).push_back(b)
#define llvec vector<vector<ll>>
#define charvec vector<vector<char>>
#define sizeoof(a,b) (a,vector<ll>(b))
#define llpvec vector<pair<ll,ll>>
/*繰り上げ除算*/ll cei(ll x,ll y){ll ans=x/y;if(x%y!=0)ans++;return ans;}
/*最大公約数*/ll gcd(ll x,ll y){return y?gcd(y,x%y):x;}
/*最小公倍数*/ll lcm(ll x,ll y){return x/gcd(x,y)*y;}
/*n乗*/ll llpow(ll x,ll n){ll i,ans=1;rep(i,0,n)ans*=x;return ans;}
/*階乗*/ll fact(ll x){ll i,ans=1;rep(i,0,x)ans*=(x-i);return ans;}
/*nCr*/ll ncr(ll n,ll r){return fact(n)/fact(r)/fact(n-r);}
/*nPr*/ll npr(ll n,ll r){return fact(n)/fact(n-r);}
/*primejudge*/bool prime(ll a){if(a<=1)return false;ll i;for(i=2;i*i<=a;i++){if(a%i==0)return false;}return true;}
ll ans=0;llfor;///////////////////////////////////////////////////////////
int main(){
  string S;
  cin>>S;
  int N=S.size();
  int m=1000;
  for(int i=0;i<=N-2;i++){
    string T=S[i]+S[i+1]+S[i+2];
    int K=stoi(T);
    m=min(m,bs(K-753));
  }
  cout<<m;
return 0;}


Compiler output:
a.cc: In function 'int main()':
a.cc:54:25: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   54 |     string T=S[i]+S[i+1]+S[i+2];
a.cc:56:13: error: 'bs' was not declared in this scope; did you mean 'abs'?
   56 |     m=min(m,bs(K-753));
      |             ^~
      |             abs
Language: C++

#include<stdio.h>
#include<iostream>
#include<vector>
#include<math.h>
#include<queue>
#include<map>
#include<algorithm>
#include<string.h>
#include<functional>
#include<limits.h>
#include<stdlib.h>
#include<string>
#include<unordered_map>
#include <iomanip>
using namespace std;
 
#define intmax INT_MAX
#define lmax LONG_MAX
#define uintmax UINT_MAX
#define ulmax ULONG_MAX
#define llmax LLONG_MAX
#define ll long long
#define rep(i,a,N) for((i)=(a);(i)<(N);(i)++)
#define rrp(i,N,a) for((i)=(N)-1;(i)>=(a);(i)--)
#define llfor ll i,j,k
#define sc(a) cin>>a
#define pr(a) cout<<a<<endl
#define pY puts("YES")
#define pN puts("NO")
#define py puts("Yes")
#define pn puts("No")
#define pnn printf("\n")
#define sort(a) sort(a.begin(),a.end())
#define push(a,b) (a).push_back(b)
#define llvec vector<vector<ll>>
#define charvec vector<vector<char>>
#define sizeoof(a,b) (a,vector<ll>(b))
#define llpvec vector<pair<ll,ll>>
/*繰り上げ除算*/ll cei(ll x,ll y){ll ans=x/y;if(x%y!=0)ans++;return ans;}
/*最大公約数*/ll gcd(ll x,ll y){return y?gcd(y,x%y):x;}
/*最小公倍数*/ll lcm(ll x,ll y){return x/gcd(x,y)*y;}
/*n乗*/ll llpow(ll x,ll n){ll i,ans=1;rep(i,0,n)ans*=x;return ans;}
/*階乗*/ll fact(ll x){ll i,ans=1;rep(i,0,x)ans*=(x-i);return ans;}
/*nCr*/ll ncr(ll n,ll r){return fact(n)/fact(r)/fact(n-r);}
/*nPr*/ll npr(ll n,ll r){return fact(n)/fact(n-r);}
/*primejudge*/bool prime(ll a){if(a<=1)return false;ll i;for(i=2;i*i<=a;i++){if(a%i==0)return false;}return true;}
ll ans=0;llfor;///////////////////////////////////////////////////////////
int main(){
  string S;
  cin>>S;
  int N=S.size();
  int m=1000;
  for(int i=0;i<=N-2;i++){
    string T=S[i]+S[i+1]+S[i+2];
    int K=stoi(T);
    m=min(m,bs(K-753));
  }
  cin>>m;
  cout<<A+B;
return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:54:25: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   54 |     string T=S[i]+S[i+1]+S[i+2];
a.cc:56:13: error: 'bs' was not declared in this scope; did you mean 'abs'?
   56 |     m=min(m,bs(K-753));
      |             ^~
      |             abs
a.cc:59:9: error: 'A' was not declared in this scope
   59 |   cout<<A+B;
      |         ^
a.cc:59:11: error: 'B' was not declared in this scope
   59 |   cout<<A+B;
      |           ^
Language: C++

#include<bits/stdc++.H>
using namespace std;
int main()
{
    long long int i,j;
   string s;
    long long int x=10000;
   cin>>s;
   for(i=0;i+2<s.size();i++)
   {
       string q;
       for(j=i;j<i+3;j++)
       {
           q+=s[j];
       }
       long long int l=stoi(q);
       //cout<<l<<endl;
       x=min(x,abs(753-l));
   }
    cout<<x;
}


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

//┏━┓┏┓
//┃//┃┗╋┓
//┃//┗━╋┛
//┃//////┃
//┃//┏━┛
//┃//┣━┓
//┗┳┛//┗┓ド
//　┗┓//┏┛　キ
//　┏┛//┗┓
//ド┗┓//┏(⌒⌒)
//　キ┗━┛ ＼／

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


int main() {
int s;
  cin>>s;
  vector<int> sum((int)s.size()-2);
  for(int i=0;i<(int)s.size-2){
  string a=s[i]+s[i+1]+s[i+2];
    int b=(int)a;
    sum[i]=b;
  }
  int ryo=1000;
  for(int j=0;j<(int)s.size-2;i++){
    ryo= min(abs(sum[i]-753),ryo);
  }
  cout <<ryo <<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:26: error: request for member 'size' in 's', which is of non-class type 'int'
   22 |   vector<int> sum((int)s.size()-2);
      |                          ^~~~
a.cc:23:24: error: request for member 'size' in 's', which is of non-class type 'int'
   23 |   for(int i=0;i<(int)s.size-2){
      |                        ^~~~
a.cc:23:30: error: expected ';' before ')' token
   23 |   for(int i=0;i<(int)s.size-2){
      |                              ^
      |                              ;
a.cc:24:13: error: invalid types 'int[int]' for array subscript
   24 |   string a=s[i]+s[i+1]+s[i+2];
      |             ^
a.cc:24:18: error: invalid types 'int[int]' for array subscript
   24 |   string a=s[i]+s[i+1]+s[i+2];
      |                  ^
a.cc:24:25: error: invalid types 'int[int]' for array subscript
   24 |   string a=s[i]+s[i+1]+s[i+2];
      |                         ^
a.cc:25:11: error: invalid cast from type 'std::string' {aka 'std::__cxx11::basic_string<char>'} to type 'int'
   25 |     int b=(int)a;
      |           ^~~~~~
a.cc:29:24: error: request for member 'size' in 's', which is of non-class type 'int'
   29 |   for(int j=0;j<(int)s.size-2;i++){
      |                        ^~~~
a.cc:29:31: error: 'i' was not declared in this scope
   29 |   for(int j=0;j<(int)s.size-2;i++){
      |                               ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
typedef long long ll;
#define _GLIBCXX_DEBUG
typedef vector<int> vec;
typedef vector<ll> lvec;
typedef vector<char> cvec;
typedef vector<double> dvec;
typedef pair<ll, ll> LP;
typedef tuple<ll, ll, ll> LT;
typedef pair<int, int> P;
typedef tuple<int, int, int> T;
#define fs first
#define sc second
int main()	{
  string s;
  cin>>s;
  int num;
  int ans=1000;
  rep(i,s.size()-2){
    string str=(s[i]-'0')+(s[i+1]-'0')+(s[i+2]-'0');
    num=stoi(str);
    ans=min(abs(753-num),ans);
  }
  cout<<ans<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:39: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   24 |     string str=(s[i]-'0')+(s[i+1]-'0')+(s[i+2]-'0');
      |                ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
typedef long long ll;
#define _GLIBCXX_DEBUG
typedef vector<int> vec;
typedef vector<ll> lvec;
typedef vector<char> cvec;
typedef vector<double> dvec;
typedef pair<ll, ll> LP;
typedef tuple<ll, ll, ll> LT;
typedef pair<int, int> P;
typedef tuple<int, int, int> T;
#define fs first
#define sc second
int main()	{
  string s;
  cin>>s;
  int num;
  int ans=1000;
  rep(i,s.size()-2){
    string str=(char)s[i]+(char)s[i+1]+(char)s[i+2];
    num=stoi(str);
    ans=min(abs(753-num),ans);
  }
  cout<<ans<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:39: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   24 |     string str=(char)s[i]+(char)s[i+1]+(char)s[i+2];
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
typedef long long ll;
#define _GLIBCXX_DEBUG
typedef vector<int> vec;
typedef vector<ll> lvec;
typedef vector<char> cvec;
typedef vector<double> dvec;
typedef pair<ll, ll> LP;
typedef tuple<ll, ll, ll> LT;
typedef pair<int, int> P;
typedef tuple<int, int, int> T;
#define fs first
#define sc second
int main()	{
  string s;
  cin>>s;
  int num;
  int ans=1000;
  rep(i,s.size()-2){
    string str=s[i]+s[i+1]+s[i+2];
    num=stoi(str);
    ans=min(abs(753-num),ans);
  }
  cout<<ans<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:27: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
   24 |     string str=s[i]+s[i+1]+s[i+2];