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

include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n;
	cin>>n;
	int alphabet[26]={0};
	for(int i=0; i<n; i++){
		int curr[26]={0};
		string s;
		cin>>s;
		for(int j=0; s[j]; j++) curr[s[j]-'a']++;
		if(!i){
			for(int j=0; j<26; j++) alphabet[j] = curr[j];
		}
		else{
			for(int j=0; j<26; j++) alphabet[j] = min(alphabet[j],curr[j]);
		}
	}
	for(int i=0; i<26; i++){
		if(alphabet[i]){
			for(int j=0; j<alphabet[i]; j++) cout<<(char)('a'+i);
		}
	}
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:9: error: 'cin' was not declared in this scope
    6 |         cin>>n;
      |         ^~~
a.cc:10:17: error: 'string' was not declared in this scope
   10 |                 string s;
      |                 ^~~~~~
a.cc:11:22: error: 's' was not declared in this scope
   11 |                 cin>>s;
      |                      ^
a.cc:17:63: error: 'min' was not declared in this scope; did you mean 'main'?
   17 |                         for(int j=0; j<26; j++) alphabet[j] = min(alphabet[j],curr[j]);
      |                                                               ^~~
      |                                                               main
a.cc:22:58: error: 'cout' was not declared in this scope
   22 |                         for(int j=0; j<alphabet[i]; j++) cout<<(char)('a'+i);
      |                                                          ^~~~
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 < (N); i++)
#define erep(i,N) for(int i = N - 1; i >= 0; i--)
const ll INF = 1000000000;
//const ll MOD = 1000000007;
const ld PI = (acos(-1));
using Graph = vector<vector<int>>;
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return true;} return false;}
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true;} return false;}
typedef pair<int, int> P;
double rad(double a) {return a * 180 / PI;}

struct UnionFind {
    vector<int> par; // par[i]:iの親の番号 (例) par[3] = 2 : 3の親が2

    UnionFind(int N) : par(N) { //最初は全てが根であるとして初期化
        for(int i = 0; i < N; i++) par[i] = i;
    }

    int root(int x) { // データxが属する木の根を再帰で得る：root(x) = {xの木の根}
        if (par[x] == x) return x;
        return par[x] = root(par[x]);
    }

    void unite(int x, int y) { // xとyの木を併合
        int rx = root(x); //xの根をrx
        int ry = root(y); //yの根をry
        if (rx == ry) return; //xとyの根が同じ(=同じ木にある)時はそのまま
        par[rx] = ry; //xとyの根が同じでない(=同じ木にない)時：xの根rxをyの根ryにつける
    }

    bool same(int x, int y) { // 2つのデータx, yが属する木が同じならtrueを返す
        int rx = root(x);
        int ry = root(y);
        return rx == ry;
    }
};

//dpTable
int dp[100050];

int main(){
    int N;
    cin >> N;
    vector<string> S(N);
    rep (i,N) cin >> S.at(i);
    vector<vector<int>> cnt(N,vector<int>(26,0));
    rep (i,N) {
        rep (j,S.at(i).size()) {
            cnt.at(i).at(S.at(i).at(j) - 'a')++;
        }
    }
    vector<int> ans(26,100000000);
    for (int i = 0; i < N; i++) {
        for (int j = 0; j < 26; j++) {
            ans.at(j) = min(ans.at(j),cnt.at(i).at(j));
        }
    }
    for (int i = 0; i < 26; i++) {
        for (int j = 0; j < ans.at(i); j++) {
            cout << (char)(i + 'a');
        }
    }
    cout << endl;
    return 0;
}

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

#include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <numeric>
#include <queue>
#include <set>
#include <vector>
using namespace std;
#define rep(i, j, n) for (int i = j; i < (int)n; ++i)

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

  vector<int> cnt(26, INF);
  rep(i, 0, n) {
    string s;
    cin >> s;
    vector<int> tmp(26);
    for (char c : s) tmp[c - 'a']++;
    rep(i, 0, 26) { cnt[i] = min(cnt[i], tmp[i]); }
  }

  string ans = "";
  rep(i, 0, 26) { rep(j, 0, cnt[i]) ans += (char)(i + 'a'); }
  cout << ans << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:23: error: 'INF' was not declared in this scope
   16 |   vector<int> cnt(26, INF);
      |                       ^~~
Language: C++

#include <bits/stdc++.h>
using ll = long long;
using namespace std;
#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 repi(i, x) \
	for (auto i = (x).begin(), i##_fin = (x).end(); i != i##_fin; i++)
#define all(x) (x).begin(), (x).end()
#define F first
#define S second
#define mp make_pair
#define pb push_back
#define solve(a) ((a) ? "Yes" : "No")
typedef vector<int> Vi;
typedef vector<Vi> VVi;
typedef pair<int, int> Pi;
typedef vector<Pi> VPi;
typedef vector<long long> V;
typedef vector<V> VV;
typedef pair<long long, long long> P;
typedef vector<P> VP;
template <class T>
inline bool chmax(T& a, T b) {
	if (a < b) {
		a = b;
		return 1;
	}
	return 0;
}
template <class T>
inline bool chmin(T& a, T b) {
	if (a > b) {
		a = b;
		return 1;
	}
	return 0;
}
const long long INFLL = 1LL << 60;
const int INF         = 1 << 30;
const double PI       = acos(-1);
int main() {
	int n;
	int ans = 0;
	cin >> n;
	map<char, int> dis, tmp;
	string s;
	for (char a = 'a'; a <= 'z'; a++) {
		dis[a] = INF;
	}
	rep(i, n) {
		cin >> s;
		tmp.clear();
		rep(j, s.size()) { tmp[s[j]]++; }
		for (char a = 'a'; a <= 'z'; a++) {
			chmin(dis[a], tmp[a]);
		}
	}
	rep(char a = 'a'; a <= 'z'; a++) {
		rep(i, dis[a]) { cout << a; }
	}
	cout << endl;
}

Compiler output:
a.cc:60:40: error: macro "rep" requires 2 arguments, but only 1 given
   60 |         rep(char a = 'a'; a <= 'z'; a++) {
      |                                        ^
a.cc:4:9: note: macro "rep" defined here
    4 | #define rep(i, n) for (int i = 0, i##_len = (int)(n); i < i##_len; i++)
      |         ^~~
a.cc: In function 'int main()':
a.cc:60:9: error: 'rep' was not declared in this scope
   60 |         rep(char a = 'a'; a <= 'z'; a++) {
      |         ^~~
Language: C++

#include <iostream>
#include <algorithm>
#include <string>
#include <cstdlib>

using namespace std;

int main()	{
  int n;
  cin >> n;
  string dict[n];
  for (int i = 0; i < n; i++)	{
    cin >> dict[i];
    sort(dict[i].begin(), dict[i].end);
  }
  string c = dict[0];
  string d;
  sort(c.begin(), c.end());
  string::iterator it;
  it = set_intersection(dict[0].begin(), dict[0].end(), c.begin(), c.end(), d.begin());
  for (int i = 1; i < n; i++)	{
	it = set_intersection(d.begin(), d.end(), dict[i].begin(), dict[i].end(), d.begin());
  }
  for (auto x = d.begin(); x != it; x++)	{
    cout << *x;
  }
  cout << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:9: error: no matching function for call to 'sort(std::__cxx11::basic_string<char>::iterator, <unresolved overloaded function type>)'
   14 |     sort(dict[i].begin(), dict[i].end);
      |     ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:4762:5: note: candidate: 'void std::sort(_RAIter, _RAIter) [with _RAIter = __gnu_cxx::__normal_iterator<char*, __cxx11::basic_string<char> >]'
 4762 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4762:63: note:   no known conversion for argument 2 from '<unresolved overloaded function type>' to '__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >'
 4762 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last)
      |                                         ~~~~~~~~~~~~~~~~~~~~~~^~~~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note: candidate: 'template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare)'
 4793 |     sort(_RandomAccessIterator __first, _RandomAccessIterator __last,
      |     ^~~~
/usr/include/c++/14/bits/stl_algo.h:4793:5: note:   candidate expects 3 arguments, 2 provided
In file included from /usr/include/c++/14/algorithm:86:
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator, class _Compare> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator, _Compare)'
  292 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last, _Compare __comp);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:292:1: note:   candidate expects 4 arguments, 2 provided
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note: candidate: 'template<class _ExecutionPolicy, class _RandomAccessIterator> __pstl::__internal::__enable_if_execution_policy<_ExecutionPolicy, void> std::sort(_ExecutionPolicy&&, _RandomAccessIterator, _RandomAccessIterator)'
  296 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last);
      | ^~~~
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note:   candidate expects 3 arguments, 2 provided
Language: C++

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

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

    string ans = "";
    string s[n];
    for(int i = 0; i < n; i++){
        cin >> s[i];
    }

    string s1 = s[0];
    sort(s1.begin(), s1.end());

    for(int i = 0; i < s1.size(); i++){
        bool find = true;
        string s2;
        for(int j = 1; j < n; j++){
            s2 = s[j];
            if(s2.find(s1[i]) == std::string::npos){
                find = false;
                break;
            }
        }

        if(find == true){
            ans.push_back(s1[i]);
        }
    }

    cout << ans << endl;

    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:5: error: 'sort' was not declared in this scope; did you mean 'short'?
   16 |     sort(s1.begin(), s1.end());
      |     ^~~~
      |     short
Language: C++

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

int main(){
    int n;
    cin >> n;
    vector<int> alp(26,0);
    rep(i,n){
        string s;
        cin >> s;
        vector<int> now(26);
        rep(j,s.size()) now[s[j] - 'a']++;
        if(i == 0){
            alp[j] = now[j];
        }
        else{
            rep(i,26) alp[j] = min(alp[j],now[j]);
        }
    }
    rep(i,26){
        cout << string(alp[i],i+'a');
    }
    cout << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:17: error: 'j' was not declared in this scope
   17 |             alp[j] = now[j];
      |                 ^
a.cc:20:27: error: 'j' was not declared in this scope
   20 |             rep(i,26) alp[j] = min(alp[j],now[j]);
      |                           ^
Language: C++

#include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i ,n) for(int i = 0 ; i < (n) ; i ++ )
#define all(x) (x).begin(),(x).end()
using namespace std;
using ll = long long;
using vin=vector<int>;
const int inf=1e9+7;
const ll INF=1e18;

int main() {
 int n;
  cin>>n;
  vector<string> s(n);
  rep(i,n) cin>>s[i];
  /////
  map<char,int> mp;
  簡単な方法がわからないめんどい良い良い良い良いい
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:3: error: '\U00007c21\U00005358\U0000306a\U000065b9\U00006cd5\U0000304c\U0000308f\U0000304b\U00003089\U0000306a\U00003044\U00003081\U00003093\U00003069\U00003044\U0000826f\U00003044\U0000826f\U00003044\U0000826f\U00003044\U0000826f\U00003044\U00003044' was not declared in this scope
   18 |   簡単な方法がわからないめんどい良い良い良い良いい
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include <iostream>
#include <unordered_map>
#include <vector>
#include <map>
#include <set>
#include <algorithm>
#define ll long long
#define pr pair<int,int>
#define all vec.begin(),vec.end()
#define REP(i,a,b) for (int i = a; i < b; i++)
#define fi first
#define se second
#define pushb push_back
#define makep make_pair

using namespace std;

int main(){
	int size;
	cin >> size;
	string arr[size];
	int ch[size][26];
	memset(ch,0,sizeof(ch));
	string k;
	for(int i = 0; i < size; i++){
		cin >> k;
		for(int j = 0; j < k.size(); j++){
			ch[i][k[j] - 'a']++;
		}
	}
	for(int j = 0; j < 26; j++){
		int min = 2e9;
		REP(i,0,size){
			if(ch[i][j] < min)
				min = ch[i][j];	
		}
		REP(z,0,min)
			cout << (char)(j + 'a');
	}
	return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:23:9: error: 'memset' was not declared in this scope
   23 |         memset(ch,0,sizeof(ch));
      |         ^~~~~~
a.cc:7:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    6 | #include <algorithm>
  +++ |+#include <cstring>
    7 | #define ll long long
Language: C++

#include <iostream>
#include <vector>
#include <string>
#include <algorithm>
#include <cmath>
#include <queue>
#include <climits>
#include <set>
#include <map>
#include <stack>
#include <iomanip>
#include <tuple>
#define ll long long
#define rep(i,s,n) for(ll i = (ll)(s); i < (ll)(n); i++)
#define all(a) (a).begin(),a.end()
#define mod 1000000007
using namespace std;
using graph =vector<vector<ll>>;
/*階乗*/
ll factorial(ll n){
    if(n==0){
        return 1;
    }
    else{
        return n*factorial(n-1);
    }
}

/* ユークリッドの互除法 最大公約数*/
ll gcd(ll a, ll b) {
	return b ? gcd(b,a%b) : a;
}



/*最小公倍数*/

ll lcm(ll a,ll b){
	return a/gcd(a,b)*b;
}


/*二点間の距離*/
double dist(pair<double,double> a,pair<double,double> b){
	return sqrt(pow((a.first - b.first) ,2) + pow((a.second - b.second),2));
}

//繰り返し自乗法
double ism(double aa,ll p){
    double ap=aa;
    double ans=1;
    while(p>0){
        //cout<<"p="<<p<<",ap="<<ap<<endl;
        if(p&1){//奇数が真
            ans*=ap;
        }
        p/=2;
        ap=ap*ap;
    }
    return ans;

}
//繰り返し自乗法(アマリトリバージョン)
ll ismm(ll aa,ll p,ll m){
    ll ap=aa;
    ll ans=1;
    while(p>0){
        //cout<<"p="<<p<<",ap="<<ap<<endl;
        if(p&1){//奇数が真
            ans=(ans*ap)%m;    
        }
        p/=2;              
        ap=(ap*ap)%m;
    }
    return ans;

}
/*
ll solve(ll i,ll m,vector<ll>t,ll n){
    if(m==0){
        return 1;
    }
    if(i>=n){
        return 0;
    }
    
    
    cout<<i+1<<" "<<m<<endl;
    cout<<i+1<<" "<<m-t[i]<<endl;
    ll res=solve(i+1,m,t,n)||solve(i+1,m-t[i],t,n);
    return res;
}
*/

//小数点12桁
struct all_init
{
    all_init()
    {
        cout << fixed << setprecision(12);
    }
} All_init;


int main()
{
    ll n;
    cin>>n;
    vector<ll>ans(26,LLONG_MAX);
    rep(i,0,n){
        string o;
        cin>>o;
        vector<ll>cnt(26,0);
        rep(j,0,o.size()){
            cnt[o[j]-'a']++;
        }
        rep(j,0,26){
            ans[j]=min(ans[j],cnt[j]);
        }
    }
    string s; 
    rep(j,0,26){
        if(ans[j]>0){
            s+=string(ans[j],i+'a');
        }
    }
    cout<<s<<endl;


    
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:124:30: error: 'i' was not declared in this scope
  124 |             s+=string(ans[j],i+'a');
      |                              ^
Language: C++

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

#define rep(i,n) for(int i = 0; i < n; i++)

int main(){
  int n;
  cin >> n;
  vector<string> s(n);
  rep(i,n)cin>>s.at(i);
  rep(j,26){
    m = 100;
    rep(i,n)m = min(m,(int) count(s.at(i).begin(),s.at(i).end(),(char)('a'+j)));
    rep(i,m)cout<<(char)('a'+j);
  }
  cout<<endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'm' was not declared in this scope
   12 |     m = 100;
      |     ^
Language: C++

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

#define rep(i,n) for(int i = 0; i < n; i++)

int main(){
  int n;
  cin >> n;
  vector<string> s(n);
  rep(i,n)cin>>s.at(i);
  rep(j,26){
    m = 100;
    rep(i,n)m = min(m, count(s.at(i).begin(),s.at(i).end(),(char)('a'+j)));
    rep(i,m)cout<<(char)('a'+j);
  }
  cout<<endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'm' was not declared in this scope
   12 |     m = 100;
      |     ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int n;cin>>n;vector<int>X(26,50);
  for(int i=0;i<n;i++){
    string S;cin>>S;char w='a';
    for(int j=0;j<26;j++){
      X.at(j)=min(X.at(j),count(S.begin(),S.end(),w));
      w++;
    }
  }
  for(int i=0;i<26;i++){
    char w='a';w+=i;
    for(int j=0;j<X.at(i);j++)cout<<w;
  }
  cout<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:18: error: no matching function for call to 'min(__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type&, std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type)'
    8 |       X.at(j)=min(X.at(j),count(S.begin(),S.end(),w));
      |               ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 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:8:18: note:   deduced conflicting types for parameter 'const _Tp' ('int' and 'std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type' {aka 'long int'})
    8 |       X.at(j)=min(X.at(j),count(S.begin(),S.end(),w));
      |               ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/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:
/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:8:18: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    8 |       X.at(j)=min(X.at(j),count(S.begin(),S.end(),w));
      |               ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int n;cin>>n;vector<int>X(26,50);
  for(int i=0;i<n;i++){
    string S;cin>>S;
    for(int j=0;j<26;j++)X.at(j)=min(X.at(j),count(S.begin(),S.end(),'a'+j));
  }
  for(int i=0;i<26;i++)for(int j=0;j<X.at(i);j++)cout<<'a'+i;
  cout<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:37: error: no matching function for call to 'min(__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type&, std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type)'
    7 |     for(int j=0;j<26;j++)X.at(j)=min(X.at(j),count(S.begin(),S.end(),'a'+j));
      |                                  ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 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:7:37: note:   deduced conflicting types for parameter 'const _Tp' ('int' and 'std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type' {aka 'long int'})
    7 |     for(int j=0;j<26;j++)X.at(j)=min(X.at(j),count(S.begin(),S.end(),'a'+j));
      |                                  ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/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:
/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:7:37: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    7 |     for(int j=0;j<26;j++)X.at(j)=min(X.at(j),count(S.begin(),S.end(),'a'+j));
      |                                  ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main() {
  vector<int> cnt[256];
  vector<char> alp(26);
  iota(alp.begin(), alp.end(), 'a');
  int n; cin >> n;
  for (int i = 0; i < n; i++) {
    string s; cin >> s;
    for (char c : alp) {
      cnt[c].push_back(count(s.begin(), s.end(), c));
    }
  }
  for (char c : alp) {
    cout << string(*min_elements(cnt[c].begin(), cnt[c].end()), c);
  }
  cout << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:21: error: 'min_elements' was not declared in this scope
   15 |     cout << string(*min_elements(cnt[c].begin(), cnt[c].end()), c);
      |                     ^~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>

using namespace std ; 

int main () { 
	ios_base::sync_with_stdio(false);
	cin.tie(NULL) ; 
	
	int n ; 
	vector <string> s ; 
	cin >> n ; 
	while ( n-- ) {
		string a ; 
		cin >> a ; 
		s.push_back(a) ; 
	}
	int arr[26] ; 
	for ( int i = 'a' ; i <= 'z' ; i ++ ) { 
		char c = i ;
		int minimum = 51 ; 
	for ( auto & str : s ) {
		minimum = min(minimum,count(str.begin(),str.end(),c) );
	}
	arr[i-'a'] = minimum ; 
}
	for ( int i = 0 ; i < 26 ; i ++ ) {
		if ( arr[i] != 0 ) {
			for ( int j = 0 ; j < arr[i] ; j ++ ) {
				cout << char(i +'a') ;
			}
		}
	}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:30: error: no matching function for call to 'min(int&, std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type)'
   22 |                 minimum = min(minimum,count(str.begin(),str.end(),c) );
      |                           ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 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:22:30: note:   deduced conflicting types for parameter 'const _Tp' ('int' and 'std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type' {aka 'long int'})
   22 |                 minimum = min(minimum,count(str.begin(),str.end(),c) );
      |                           ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/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:
/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:22:30: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
   22 |                 minimum = min(minimum,count(str.begin(),str.end(),c) );
      |                           ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h> 
using namespace std;
#define rep(i, N) for(int i=0; i<N; i++)
typedef long long ll;
#define dump(x) cerr<<#x<<"="<<x<<endl
using P = pair<int, int>;

int main() {
    int n; cin >> n;
    vector<string> s(n);
    rep(i, n){
        cin >> s.at(i);
    }

    if(n==1){
        cout << s.at(0) << endl;
        return 0;
    }

    string v = "";
    for(int i=0; i<s.at(0).size(); i++){
        bool ok = false;
        for(int j=1; j<n; j++){
            bool notok = false;
            for(int k=0; k<s.at(j).size(); k++){
                if(s.at(0).at(i)==s.at(j).at(k)) {
                    s.at(j).at(k) = '!'; 
                    break;
                }

                if(k==s.at(j).size()-1){
                   notok = true; 
                }
            }
            if(notok) break;

            if(j==n-1){
                ok = true;
            }
        }
        if(ok){
            v.push_back(s.at(0).at(i));
        }
    }

    if(v.size()!=0) {
        sort(v.begin(), v.end());
        cout << v << +e3ndl;
    }
    else cout << endl;

    return 0;
}


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

#include<bits/stdc++.h>
#include <iostream>
#include <string>
#include <cmath>
using namespace std;
#define ll long long
#define rep(i, n) for (ll i = 0; i < (n); i++)
#define FOR(i,a,b) for(ll i=(a);i<(b);i++)
#define FORR(i,a,b)for(ll i=(a);i<=(b);i++)
#define repR(i,n) for(ll i=n;i>=0;i--)
#define all(v)(v).begin(),(v).end()
#define rall(v)(v).rbegin(),(v).rend()
#define F first
#define S second
#define pb push_back
#define pu push
#define COUT(x) cout<<(x)<<endl
#define PQ priority_queue<ll>
#define PQR priority_queue<ll,vector<ll>,greater<ll>>
#define YES(n) cout << ((n) ? "YES" : "NO"  ) << endl
#define Yes(n) cout << ((n) ? "Yes" : "No"  ) << endl
#define mp make_pair
#define maxs(x,y) (x = max(x,y))
#define mins(x,y) (x = min(x,y))
#define sz(x) (int)(x).size()
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
const ll MOD = 1000000007LL;
const ll INF = 1LL << 60;
using vll = vector<ll>;
using vb = vector<bool>;
using vvb = vector<vb>;
using vvll = vector<vll>;
using vstr = vector<string>;
using pll = pair<ll, ll>;
ll gcd(ll a, ll b) { return b?gcd(b,a%b):a;}
ll lcm(ll a, ll b) { return a/gcd(a,b)*b;}
int main(){
  ll n;
  cin>>n;
  vstr s(n);
  vvll t(n,vll(26));
  rep(i,n){
    cin>>s[i];
    sort(all(s[i]));
    rep(j,s[i].size()){
      t[i][s[i][j]-'a']++;
    }
  }
  vll a(26,100);
  rep(i,n){
    rep(j,26){
      a[j]=min(t[i][j],a[j]);
    }
  }
  vector<char> g(0);
  rep(i,26){
    ll h=a[i].size();
    rep(j,h){
      g.pb((char)('a'+a[i]));
    }
  }
  rep(i,g.size()){
    cout<<g[i]<<;
  }
}


  

Compiler output:
a.cc: In function 'int main()':
a.cc:58:15: error: request for member 'size' in 'a.std::vector<long long int>::operator[](((std::vector<long long int>::size_type)i))', which is of non-class type '__gnu_cxx::__alloc_traits<std::allocator<long long int>, long long int>::value_type' {aka 'long long int'}
   58 |     ll h=a[i].size();
      |               ^~~~
a.cc:64:17: error: expected primary-expression before ';' token
   64 |     cout<<g[i]<<;
      |                 ^
Language: C++

#include <iostream>
#include <algorithm>
#include <string>
#include <cmath>
#include <vector>
#include <set>
#include <queue>
#include <string>

#define rep(i, a, b) for ( int i = (a); i < (b); i++ )
#define per(i, a, b) for ( int i = (b)-1; i >= (a); i--)
#define pb push_back
#define mp make_pair
#define bg begin()
#define en end()


using namespace std;

typedef long long ll;

static const long long MOD = 1000000007;

int n;
char S[55][55];
int c[55][55];
string ans;

int main(void) {
    scanf("%d", &n);
    rep(i, 0, n) {
        scanf("%s", S[i]);
    }

    for (int i = 0; i < n; i++) {
        for (int j = 0; j < (int)strlen(S[i]); j++) {
            int ch = S[i][j] - 'a';
            c[ch][i]++;
        }
    }

    rep(ch, 0, 26) {
        int cnt = 1000000000;
        rep(i, 0, n) {
            cnt = min(cnt, c[ch][i]);
        }
        rep(i, 0, cnt) ans += 'a' + ch;

    }
    
   

  
    printf("%s\n", ans.c_str());

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:36:34: error: 'strlen' was not declared in this scope
   36 |         for (int j = 0; j < (int)strlen(S[i]); j++) {
      |                                  ^~~~~~
a.cc:8:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    7 | #include <queue>
  +++ |+#include <cstring>
    8 | #include <string>
Language: C++

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

#define rep(i, a, b) for ( int i = (a); i < (b); i++ )
#define per(i, a, b) for ( int i = (b)-1; i >= (a); i--)
#define pb push_back
#define mp make_pair
#define bg begin()
#define en end()


using namespace std;

typedef long long ll;

static const long long MOD = 1000000007;

int n;
char S[55][55];
int c[55][55];
string ans;

int main(void) {
    scanf("%d", &n);
    rep(i, 0, n) {
        scanf("%s", S[i]);
    }

    for (int i = 0; i < n; i++) {
        for (int j = 0; j < (int)strlen(S[i]); j++) {
            int ch = S[i][j] - 'a';
            c[ch][i]++;
        }
    }

    rep(ch, 0, 26) {
        int cnt = 1000000000;
        rep(i, 0, n) {
            cnt = min(cnt, c[ch][i]);
        }
        rep(i, 0, cnt) ans += 'a' + ch;

    }
    
   

  
    printf("%s\n", ans.c_str());

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:36:34: error: 'strlen' was not declared in this scope
   36 |         for (int j = 0; j < (int)strlen(S[i]); j++) {
      |                                  ^~~~~~
a.cc:9:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    8 | #include <map>
  +++ |+#include <cstring>
    9 |
Language: C++

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

int main() {
	ios::sync_with_stdio(false);
	cin.tie(0);
	int n;
	cin >> n;
	vector<string> s(n);
	rep(i, n) cin >> s[i];

	string ans = "";
	for (char i = 'a'; i <= 'z'; ++i) {
		int k = 100;
		rep(j, n) {
			k = min(k, count(all(s[j]), i));
		}
		if (k == 100) continue;
		while (k > 0) {
			ans += i;
			k--;
		}
	}

	sort(all(ans));
	cout << ans << endl;

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:20:32: error: no matching function for call to 'min(int&, std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type)'
   20 |                         k = min(k, count(all(s[j]), i));
      |                             ~~~^~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 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:20:32: note:   deduced conflicting types for parameter 'const _Tp' ('int' and 'std::__iterator_traits<__gnu_cxx::__normal_iterator<char*, std::__cxx11::basic_string<char> >, void>::difference_type' {aka 'long int'})
   20 |                         k = min(k, count(all(s[j]), i));
      |                             ~~~^~~~~~~~~~~~~~~~~~~~~~~~
/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:
/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:20:32: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
   20 |                         k = min(k, count(all(s[j]), i));
      |                             ~~~^~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include <iostream>
using namespace std;
int cnt[26][50];
string s[50];
int main()
{
    int n;
    cin>>n;
    string ans="";
    for(int i=0;i<n;i++)
    {
        cin>>s[i];
        for(int j=0;j<s[i].size();j++)
            cnt[s[i][j]-'a'][i]++;
    }
    for(int i=0;i<26;i++)
    {
        sort(cnt[i],cnt[i]+n);
        ans.append(cnt[i][0], 'a'+i);
    }
    cout<<ans<<endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:9: error: 'sort' was not declared in this scope; did you mean 'short'?
   18 |         sort(cnt[i],cnt[i]+n);
      |         ^~~~
      |         short
Language: C++

#include<bits/stdc++.h>
using namespace std;
#define rep(i,j,n) for(int i=(int)(j);i<(int)(n);i++)
#define REP(i,j,n) for(int i=(int)(j);i<=(int)(n);i++)
#define MOD 1000000007
#define int long long
#define ALL(a) (a).begin(),(a).end()
#define vi vector<int>
#define vii vector<vi>
#define pii pair<int,int>
#define priq priority_queue<int>
#define disup(A,key) distance(A.begin(),upper_bound(ALL(A),(int)(key)))
#define dislow(A,key) distance(A.begin(),lower_bound(ALL(A),(int)(key)))
signed main(){
  int N;
  cin>>N;
  vi A(26);
  string S;
  cin>>S;
  rep(i,0,S.size())
    A[S[i]-'a']++;
  rep(i,1,N){
    string X;
    cin>>X;
    vi B(26);
    rep(j,0,X.size())
      B[S[j]-'a']++;
    rep(j,0,26)
      A[j]=min(A[j],B[j]);
    } 
  string ans;
  rep(i,0,26){
    rep(k,0,A[i])
      ans+='a'+i;
    }
  if(ans)
    cout<<ans;
  }


Compiler output:
a.cc: In function 'int main()':
a.cc:36:6: error: could not convert 'ans' from 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'bool'
   36 |   if(ans)
      |      ^~~
      |      |
      |      std::string {aka std::__cxx11::basic_string<char>}
Language: C++

#include<iostream>
#include<cstdio>
#include<string>

using namespace std;

int n;
string s;
int a[27];
int minn[27];/

int main()
{
    cin>>n;
    for(int i=1;i<=26;i++)minn[i]=100864;
    for(int i=1;i<=n;i++)
    {
        for(int j=1;j<=26;j++)a[j]=0;
        cin>>s;
        for(auto j:s)a[j-'a'+1]++;
        for(int j=1;j<=26;j++)minn[j]=min(minn[j],a[j
    }
    for(int i=1;i<=26;i++)
        for(int j=1;j<=minn[i];j++)putchar('a'+i-1);
}

Compiler output:
a.cc:10:14: error: expected unqualified-id before '/' token
   10 | int minn[27];/
      |              ^
Language: C++

#include<bits/stdc++.h>
#define INF 1e9
#define llINF 1e18
#define MOD 1000000007
#define pb push_back
#define mp make_pair 
#define F first
#define S second
#define ll long long
#define ull unsigned long long
#define vi vector<ll>
#define vvi vector<vi>
#define BITLE(n) (1LL<<((ll)n))
#define BITCNT(n) (__builtin_popcountll(n))
#define SUBS(s,f,t) ((s).substr((f)-1,(t)-(f)+1))
#define ALL(a) (a).begin(),(a).end()
using namespace std;
int cnt[11111][26];
int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);
  ll n;cin>>n;

  for(int i=0;i<n;i++){
    string s;cin>>s;
    for(auto a:s)cnt[i][a-'a'];
  }
  vector<char>ans;
  for(int i=0;i<26;i++){
    ll mi=llINF;
    for(int j=0;j<n;j++){
      mi=min(mi,cnt[j][i]);
    }
    for(int j=0;j<mi;j++)
      ans.pb((char)(i+'a'));
  }
  for(auto a:ans)cout<<a;
  cout<<endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:32:13: error: no matching function for call to 'min(long long int&, int&)'
   32 |       mi=min(mi,cnt[j][i]);
      |          ~~~^~~~~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 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:32:13: note:   deduced conflicting types for parameter 'const _Tp' ('long long int' and 'int')
   32 |       mi=min(mi,cnt[j][i]);
      |          ~~~^~~~~~~~~~~~~~
/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:
/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:32:13: note:   mismatched types 'std::initializer_list<_Tp>' and 'long long int'
   32 |       mi=min(mi,cnt[j][i]);
      |          ~~~^~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define LOOP(i,o) for(i=0;i<o;i++)
#define ALL(a)  (a).begin(),(a).end()            
int main() {
  int n;
  cin>>n;
  vector<string> s(n);
  int i=0;
  LOOP(i,n){
    cin>>s[i];
  }
  vector<int> a(26,51);
  LOOP(i,n){
    for(int j=0;j<s.at(i).size();j++){
      int hh=1;
      if(s[i][j]==s[i][j+1]){
        hh++;
        continue;
      }
      else{
        a[s[i][j]-'a']=min(a[s[i][j]-'a'],hh);
      }
    }
  }
  for(int i=0;i<26;i++){
    if(a[i]==51) a[i]=0;
  }
  
        

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

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


int Len(int n) {
  int s=0;
  while(n!=0) s++, n/=10;
  return s;
}


int Sint(int n) {
  int m=0,s=0,a=n;
  while(a!=0) s++, a/=10;
  for(int i=s-1;i>=0;i--) m+=n/((int)pow(10,i))-(n/((int)pow(10,i+1)))*10;
  return m;
}


int GCD(int a,int b)
{
  int r, tmp;
   /* 自然数 a > b を確認・入替 */
  if(a<b){
    tmp = a;
    a = b;
    b = tmp;
  }
  /* ユークリッドの互除法 */
  r = a % b;
  while(r!=0){
    a = b;
    b = r;
    r = a % b;
  }
  return b;
}


int Factorial(int n){
  int m=1;
  while(n>=1) m*=n,n--;
  return m;
}


int Svec(vector<int> v){
  int n=0;
  for(int i=0;i<v.size();i++) n+=v[i];
  return n;
}
///////////////////////////
int main() {
  int n,ans=0;
  cin>>n;
  vector<string> v(n);
  rep(i,n) cin>>v[i];
  
  vector<map<char,int>> w(n,map<char,int>);
  rep(i,n){
    rep(j,v[i].size()){
      w[i][v[i][j]]++;
    }
  }
  
  map<char,int> mp;
  rep(i,26){
    mp['a'+i]=100;
  }
  for(int i=0;i<n;i++){
    for(auto c:w[i]){
      if(mp[c.first]>=c.second){
        mp[c.first]=c.second;
      }
    }
  }
  for(int i=0;i<n;i++){
    for(auto c:w[i]){
      if(mp[c.first]==100){
        mp[c.first]=0;
      }
    }
  }
  for(auto c:mp){
    rep(i,c.second){
      cout<<c.first;
    }
  }
  cout<<endl;
}
///////////////////////////


Compiler output:
a.cc: In function 'int main()':
a.cc:62:42: error: expected primary-expression before ')' token
   62 |   vector<map<char,int>> w(n,map<char,int>);
      |                                          ^
Language: C++

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

int n,cnt[50][30];
string s[50];
char res[51];
 
int main() {
    cin>>n;
    int index=0;
    rep(i,n) cin>>s[i];
    rep(i,n) rep(j,s.size()) cnt[i][s[i][j]-'a']++;
    rep(i,26){
        int c=cnt[0][i];
        for (int k=1;k<n;k++){
            c=min(c,cnt[k][i]);
        }
        for (int k=index;k<index+c;k++) {
            res[k]='a'+i;
        }
        index+=c;
    }
    cout<<res<<endl;  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:22: error: request for member 'size' in 's', which is of non-class type 'std::string [50]' {aka 'std::__cxx11::basic_string<char> [50]'}
   14 |     rep(i,n) rep(j,s.size()) cnt[i][s[i][j]-'a']++;
      |                      ^~~~
a.cc:4:39: note: in definition of macro 'rep'
    4 | #define rep(i, n) for(int i = 0; i < (n); i++)
      |                                       ^
Language: C++

#include <iostream>
#include <vector>

using namespace std;

vector <char> ALPHABET(26); 

int main(){
  int n;
  cin >> n;
//init APLPHABET
  for(int i = 0; i < 26; i++){
    ALPHABET[i] = char('a' + i);
  }
  
  vector<string> S(n);
  for(int i = 0; i < n; i++) cin >> S[i];
  
  vector<int> isect(26,51);
  for(a = 0; a<isect.size(); a++){
    for(int i = 0, i < n; i++){
      int l = S[i].size();
      int t = 0;
      for(int j = 0; j < l; j++){
        if(S[i][j] == ALPHABET[a]){
          tmp++;
        }
      }
      if(isect[a] > tmp) isect[a] = tmp;
    }
  }
  string ans;
  
  for(int i = 0; i < isect.size(); i++){
    int t = isect[i];
    while(t > 0){
    ans.push_back[ALPHABET[i]];
    t--;
    }
  }
  cout << ans;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:20:7: error: 'a' was not declared in this scope
   20 |   for(a = 0; a<isect.size(); a++){
      |       ^
a.cc:21:21: error: expected ';' before '<' token
   21 |     for(int i = 0, i < n; i++){
      |                     ^~
      |                     ;
a.cc:21:22: error: expected primary-expression before '<' token
   21 |     for(int i = 0, i < n; i++){
      |                      ^
a.cc:26:11: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   26 |           tmp++;
      |           ^~~
      |           tm
a.cc:29:21: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   29 |       if(isect[a] > tmp) isect[a] = tmp;
      |                     ^~~
      |                     tm
a.cc:37:18: error: invalid types '<unresolved overloaded function type>[__gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type {aka char}]' for array subscript
   37 |     ans.push_back[ALPHABET[i]];
      |                  ^
Language: C++

#include <iostream>
#include <cstdio>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <iomanip>
#include <stdlib.h>
#include <string.h>
#include <cmath>
#include <map>
#include <queue>
#include <deque>
#include <stack>
#include <set>
#define rep(i,n) for(int i=0; i<n; i++)
const long long MOD = 1000000007;
using namespace std;
typedef long long ll;

map<ll, int> mp;
signed main() {
	ios_base::sync_with_stdio(0);
	cin.tie(0);
	int n; cin >> n;
	vector<string> s(n);
	vector<vector<int>> a(n, vector<int>(26, 0));
	rep(i, n) {
		cin >> s.at(i);
		rep(j, s.at(i).size()) {
			a.at(i).at(s.at(i).at(j) - 'a')++;
		}
	}
	string ans = "";
	rep(i, 26) {
		int m = INT_MAX;
		rep(j, n) {
			m = min(m, a.at(j).at(i));
		}
		rep(j, m) {
			char c = 'a' + i;
			ans += c;
		}
	}
	cout << ans << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:36:25: error: 'INT_MAX' was not declared in this scope
   36 |                 int m = INT_MAX;
      |                         ^~~~~~~
a.cc:16:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
   15 | #include <set>
  +++ |+#include <climits>
   16 | #define rep(i,n) for(int i=0; i<n; i++)
Language: C++

#include <iostream>
#include <cstdio>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <iomanip>
#include <stdlib.h>
#include <string.h>
#include <cmath>
#include <map>
#include <queue>
#include <deque>
#include <stack>
#include <set>
#define rep(i,n) for(int i=0; i<n; i++)
const long long MOD = 1000000007;
using namespace std;
typedef long long ll;

map<ll, int> mp;
int main() {
	ios_base::sync_with_stdio(0);
	cin.tie(0);
	int n; cin >> n;
	vector<string> s(n);
	vector<vector<int>> a(n, vector<int>(26, 0));
	rep(i, n) {
		cin >> s.at(i);
		rep(j, s.at(i).size()) {
			a.at(i).at(s.at(i).at(j) - 'a')++;
		}
	}
	string ans = "";
	rep(i, 26) {
		int m = INT_MAX;
		rep(j, n) {
			m = min(m, a.at(j).at(i));
		}
		rep(j, m) {
			char c = 'a' + i;
			ans += c;
		}
	}
	cout << ans << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:36:25: error: 'INT_MAX' was not declared in this scope
   36 |                 int m = INT_MAX;
      |                         ^~~~~~~
a.cc:16:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
   15 | #include <set>
  +++ |+#include <climits>
   16 | #define rep(i,n) for(int i=0; i<n; i++)
Language: C++

#include<bits/stdc++.h>                          
using namespace std;                          
int t[200],ans[200],ch[200];
                     
int main(){
	int n;
	cin>>n;      
	string s; 
	for(int i=0;i<n;i++)
	{		
	    cin>>s;        
		for(int i=0;i<s.size();i++)
		{
		    ch[s[i]]++;	
		}  
		for(int i='a';i<='z';i++)
		{
	    	ans[i]=min(ans[i],ch[i])			
		}
    }   
	for(int i='a';i<='z';i++)
	{
		for(int j=0;j<ans[i];j++)
		{
			cout<<(char)i;
		}
	}    
	return 0;
}                                               

Compiler output:
a.cc: In function 'int main()':
a.cc:18:48: error: expected ';' before '}' token
   18 |                 ans[i]=min(ans[i],ch[i])
      |                                         ^       
      |                                                ;
   19 |                 }
      |                 ~