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

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

int main(){
  int n;
  char s[200001][11]={0}, c[11];
  int b[2000001]={0}, ans=0;
  scanf("%d", &n);
  for(int i=0; i<n; i++){
  	scanf("%s", c);
    if(b[i]==1&&strcmp(s, c[i])==0){
      continue;
    }
    else if(b[i]==0){
      s[i]=c;
      ans++;
      b[i]++;
    }
  }
  printf("%d\n", ans);

}

Compiler output:
main.c: In function 'main':
main.c:11:24: error: passing argument 1 of 'strcmp' from incompatible pointer type [-Wincompatible-pointer-types]
   11 |     if(b[i]==1&&strcmp(s, c[i])==0){
      |                        ^
      |                        |
      |                        char (*)[11]
In file included from main.c:2:
/usr/include/string.h:156:32: note: expected 'const char *' but argument is of type 'char (*)[11]'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                    ~~~~~~~~~~~~^~~~
main.c:11:28: error: passing argument 2 of 'strcmp' makes pointer from integer without a cast [-Wint-conversion]
   11 |     if(b[i]==1&&strcmp(s, c[i])==0){
      |                           ~^~~
      |                            |
      |                            char
/usr/include/string.h:156:50: note: expected 'const char *' but argument is of type 'char'
  156 | extern int strcmp (const char *__s1, const char *__s2)
      |                                      ~~~~~~~~~~~~^~~~
main.c:15:11: error: assignment to expression with array type
   15 |       s[i]=c;
      |           ^
Language: C

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

int main(void){
  int n, sum=0, flag;
  scanf("%d", &n);
  char s[n][10];
  for(int i=0;i<n;i++){
    scanf("%s", s[i]);
  }
  std::sort(s[0],s[n-1]);
  for(int j=0; j<n;j++){
  if(strcmp(s[j],s[j+1])!=0){
    sum++;
  }
  }
  printf("%d", sum);
  return 0;
}

Compiler output:
main.c:3:10: fatal error: algorithm: No such file or directory
    3 | #include <algorithm>
      |          ^~~~~~~~~~~
compilation terminated.
Language: C++

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

int main() {
    int n;
    cin >> n;
    set<string> st;
    for(int i = 0; i < n; i++) {
        string s;
        cin >> s;
        st.insert(s);
    }

    cout << st.size() << endl;
    return 0;
}

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

import numpy as np

if __name__ == "__main__":
    N=input()
    N=int(N)
    l=[]
    for i in range(N):
        buf=input()
        l+=[buf]
    l=np.array(l)
    print(len(np.unique(l)))

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import numpy as np
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
Language: C

#include<stdio.h>
#include<stdlib.h>
#include<string.h>

    char **str;

int str_compare(const void* left,const void* right){
    char *left_char=(char *)left;
    char *right_char=(char *)right;
    return strcmp(left_char,right_char);
}


}
int main(void){
    int N;
    int count=1;

    scanf("%d",&N);
    str=(char **)malloc(sizeof(char *)*N);
    for(int i=0;i<N;i++){
        str[i]=(char *)malloc(sizeof(char)*11);
    }
    for(int i=0;i<N;i++) scanf("%s",str[i]);    
    qsort(str,N,sizeof(char*),&str_compare);
    for(int i=1;i<N;i++){
        if(strcmp(str[i],str[i-1])!=0) count++;
    }
    for(int i=0;i<N;i++) printf("%s\n",str[i]);
    printf("%d\n",count);
    return 0;
}

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

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

int main() {
  int n;
  cin >> n;
  string temp;
  set<string> st;
  for(int i-0; i < n; i++)
  {
    cin >> temp;
    st.insert(temp);
  }
  cout << st.size();
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:12: error: expected ';' before '-' token
   10 |   for(int i-0; i < n; i++)
      |            ^
      |            ;
a.cc:10:21: error: expected ')' before ';' token
   10 |   for(int i-0; i < n; i++)
      |      ~              ^
      |                     )
a.cc:10:23: error: 'i' was not declared in this scope
   10 |   for(int i-0; i < n; i++)
      |                       ^
Language: C++

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

int main() {
  int n;
  cin >> n;
  set<string> st;
  rep(i, n) {
    string s;
    cin >> s
    st.insert(s);
  }
  cout << st.size() << endl;
  return 0;
}
      

Compiler output:
a.cc: In function 'int main()':
a.cc:13:13: error: expected ';' before 'st'
   13 |     cin >> s
      |             ^
      |             ;
   14 |     st.insert(s);
      |     ~~
Language: C++

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

int main()
{
  int n,ans;
  cin>>n;
  ans=1;
  vector<string> item(n);
  for(int i=0;i<n;i++)
  {
    cin>>item.at(i);
  }
  for(int i=1;i<n;i++)
  {
    int a=0;
    for(int j=i4-1;j>=0;j--)
    {
      if(item.at(i)==item.at(j))
      {
        a=1;
        break;
      }
    }
    if(a==0)
      ans++;
  }
  cout<<ans<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:17:15: error: 'i4' was not declared in this scope; did you mean 'i'?
   17 |     for(int j=i4-1;j>=0;j--)
      |               ^~
      |               i
Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for(long long i=0; i<n; i++)
#define Rep(i,n) for(long long i=1; i<n; i++)
#define ll long long
#include <math.h>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <numeric>
#include <queue>
#include <set>
#include <vector>


using namespace std;
#define PI acos(-1)




int main(){
    int N;
    cin>>N;
    set<string>s;
    int ans=0;
    rep(i,N){
       string s;
       cin>>s;
       st.insert(s);
    }
  cout<<st.size()<<endl;
  return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:29:8: error: 'st' was not declared in this scope; did you mean 's'?
   29 |        st.insert(s);
      |        ^~
      |        s
a.cc:31:9: error: 'st' was not declared in this scope; did you mean 's'?
   31 |   cout<<st.size()<<endl;
      |         ^~
      |         s
Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for(long long i=0; i<n; i++)
#define Rep(i,n) for(long long i=1; i<n; i++)
#define ll long long
#include <math.h>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <numeric>
#include <queue>
#include <set>
#include <vector>


using namespace std;
#define PI acos(-1)




int main(){
    int N;
    cin>>N;
    vector<string>s;
    int ans=0;
    rep(i,N){
       string S;
       cin>>S;
       st.insert(s);
    }
  cout<<st.size()<<endl;
  return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:29:8: error: 'st' was not declared in this scope; did you mean 's'?
   29 |        st.insert(s);
      |        ^~
      |        s
a.cc:31:9: error: 'st' was not declared in this scope; did you mean 's'?
   31 |   cout<<st.size()<<endl;
      |         ^~
      |         s
Language: C++

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

int main() {
  int n;
  set<string> S;
  for(int i = 0;i < n;i++) {
    string s;
    cin >> s;
    S.insert(s);
  }
  cout << s.size() << endl;
}

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

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

int main(){
  int n;cin>>n;
  set<string> st;
  string temp;
  while(i--){
    cin>>temp;
    st.insert(temp);
  }
  cout<<st.size()<<endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: 'i' was not declared in this scope
    8 |   while(i--){
      |         ^
Language: C++

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

int main(){
    int n;
    string name[200010];
    int answer = 0;

    cin >> n;

    for(int i = 0; i < n; i++){
        cin >> name[i];
    }

    sort(name,name+n);

    for(int i = 0; i < n; i++){
        if(i==0){
            answer++;
            continue;
        }
        if(name[i].compare(name[i-1]) == 1 ){
            answer ++;
        }
    }
    cout << answer;
    cout << SIZE_OF_ARRAY(name);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:28:13: error: 'SIZE_OF_ARRAY' was not declared in this scope
   28 |     cout << SIZE_OF_ARRAY(name);
      |             ^~~~~~~~~~~~~
Language: C

#include <stdio.h>
int main(void){
  int n,i,k,s=0;
  scanf("%d",&n);
  char name[n][11];
  for(i=0;i<n;i++){
  scanf("%s",name[i]);
  }
  qsort(s,n,11,strcmp);
  for(i=1;i<n;i++){
    if(strcmp(name[i],name[i-1]!=0){
      s++;
    }
  }
  printf("%d",s);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:3: error: implicit declaration of function 'qsort' [-Wimplicit-function-declaration]
    9 |   qsort(s,n,11,strcmp);
      |   ^~~~~
main.c:9:16: error: 'strcmp' undeclared (first use in this function)
    9 |   qsort(s,n,11,strcmp);
      |                ^~~~~~
main.c:2:1: note: 'strcmp' is defined in header '<string.h>'; this is probably fixable by adding '#include <string.h>'
    1 | #include <stdio.h>
  +++ |+#include <string.h>
    2 | int main(void){
main.c:9:16: note: each undeclared identifier is reported only once for each function it appears in
    9 |   qsort(s,n,11,strcmp);
      |                ^~~~~~
main.c:11:8: error: implicit declaration of function 'strcmp' [-Wimplicit-function-declaration]
   11 |     if(strcmp(name[i],name[i-1]!=0){
      |        ^~~~~~
main.c:11:8: note: include '<string.h>' or provide a declaration of 'strcmp'
main.c:11:32: error: passing argument 2 of 'strcmp' makes pointer from integer without a cast [-Wint-conversion]
   11 |     if(strcmp(name[i],name[i-1]!=0){
      |                       ~~~~~~~~~^~~
      |                                |
      |                                int
main.c:11:32: note: expected 'const char *' but argument is of type 'int'
main.c:11:36: error: expected ')' before '{' token
   11 |     if(strcmp(name[i],name[i-1]!=0){
      |       ~                            ^
      |                                    )
main.c:14:3: error: expected expression before '}' token
   14 |   }
      |   ^
Language: C

 #include<stdio.h>
 #include<string.h>
int main(void)
{
  int i, j;
  int n,sum = 0;
  scanf("%d",&n);
  char s[n][10], t[20];
  for(i = 0 ; i < num ; i++){
    scanf("%s", s[i]);
    sum++;
  }
  for(i=1 ; i<num ; i++){
    for(j = 1 ; j < num ; j++){
      if(strcmp(s[j-1], s[j]) > 0){
        strcpy(t, s[j-1]);
        strcpy(s[j-1], s[j]);
        strcpy(s[j], t);
      }
    }
    if(s[i] == s[i+1])
      sum--;
  }
  printf("%d", sum);
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:9:19: error: 'num' undeclared (first use in this function); did you mean 'sum'?
    9 |   for(i = 0 ; i < num ; i++){
      |                   ^~~
      |                   sum
main.c:9:19: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
int main(void){
  int n;
  int i;
  int sum=0;
  scanf("%d",&n);
  char a[n][11];
   for(i=1; i<=n; i++){
       scanf("%s",&a[i]);
   }

  qsort(a,n,11,strcmp);

  for(i=1; i<n; i++){
      if(strcmp(s[i] , s[i-1])!=0){
        sum++;
      }
  }
  printf("%d",sum);
   return 0;
}


Compiler output:
main.c: In function 'main':
main.c:15:16: error: passing argument 4 of 'qsort' from incompatible pointer type [-Wincompatible-pointer-types]
   15 |   qsort(a,n,11,strcmp);
      |                ^~~~~~
      |                |
      |                int (*)(const char *, const char *)
In file included from main.c:3:
/usr/include/stdlib.h:971:34: note: expected '__compar_fn_t' {aka 'int (*)(const void *, const void *)'} but argument is of type 'int (*)(const char *, const char *)'
  971 |                    __compar_fn_t __compar) __nonnull ((1, 4));
      |                    ~~~~~~~~~~~~~~^~~~~~~~
main.c:18:17: error: 's' undeclared (first use in this function)
   18 |       if(strcmp(s[i] , s[i-1])!=0){
      |                 ^
main.c:18:17: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
#include<string.h>
int main(void){
  int N;
  int c=0;
  char S[200000][10],tmp[10];
  scanf("%d",&N);
  for(int i=0;i<N;i++){
    scanf("%s"S[i]);}
  for(int l=1;l<N;l++){
    for(int j=1;j<N;j++){
      if(strcmp(S[j-1], S[j])>0){
        strcpy(tmp, S[j-1]);
        strcpy(S[j-1], S[j]);
        strcpy(S[j], tmp);
      }
    }
  }
  for(int l=0;l<N;l++){
    for(int j=0;j<N;j++){
  if(strcmp(S[l],S[j])==0){
    c++;
  }}}
  printf("%d",c);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:15: error: expected ')' before 'S'
    9 |     scanf("%s"S[i]);}
      |          ~    ^
      |               )
Language: C

#include<stdio.h>
int main()
{
  int n,i,t,c=0;
  char s[200000][11];
  scanf("%d",&n);
  for(i=0;i<n;i++)
    scanf("%d",s[i]);
  for(i=0;i<n;i++){
    for(t=0;t<n;t++){
      if(s[i]==s[s]){
        c++;
      }
    }
  }
  printf("%d",n-c);
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:11:17: error: array subscript is not an integer
   11 |       if(s[i]==s[s]){
      |                 ^
Language: C

#include<stdio.h>
int main()
{
  int n,i,s,c=0;
  char s[200000][11];
  scanf("%d",&n);
  for(i=0;i<n;i++)
    scanf("%d",s[i]);
  for(i=0;i<n;i++){
    for(s=0;s<n;s++){
      if(s[i]==s[s]){
        c++;
      }
    }
  }
  printf("%d",n-c);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:8: error: conflicting types for 's'; have 'char[200000][11]'
    5 |   char s[200000][11];
      |        ^
main.c:4:11: note: previous declaration of 's' with type 'int'
    4 |   int n,i,s,c=0;
      |           ^
Language: C

#include <stdio.h>

struct H{
  char name[10];
}

int main(void){
  int n;
  int i,x;
  struct H s[200000]; 
  
  scanf("%d",&n);
  for(i=0;i<n;i++){
    scanf("%s",&s[i].name);
  }
  
  printf("%d",x);
  return 0;
}


Compiler output:
main.c:7:1: error: expected ';', identifier or '(' before 'int'
    7 | int main(void){
      | ^~~
Language: C

#include<stdio.h>
 
int main(void){
  int n;
  scanf("%d",&n);
  
  char s[n][11];
  for(int i = 0;i < n;i++)
    scanf("%s",&s[i]);
  
  int count = 0;
  char check[n][11];
  for(int i = 0;i < n;i++){
    int flag = 1;
    int j = 0;
    while(check[j] != NULL || flag){
      if(check[j] == s[i])
        flag = 0;
      j++;
    }
    if(flag){
      while(check[j] != NULL)
        j++;
      check[j] = s[i];
      count = j;
    }
  }
  printf("%d",count);
      
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:24:16: error: assignment to expression with array type
   24 |       check[j] = s[i];
      |                ^
Language: C

#include<stdio.h>
#include <math.h>
int main(void){
  int n;
  int i;
  int sum=0;
  scanf("%d",&n);
  char s[n];
   for(i=1; i<=n; i++){
       scanf("%s",&s[i]);
   }

  qsort(s,n,sizeof(char),strcmp);

  for(int i=1;i<n;i++){
      if(strcmp(s[i],s[i-1])!=0){
        sum++;
      }
  }
  printf("%d",sum);
   return 0;
}


Compiler output:
main.c: In function 'main':
main.c:13:3: error: implicit declaration of function 'qsort' [-Wimplicit-function-declaration]
   13 |   qsort(s,n,sizeof(char),strcmp);
      |   ^~~~~
main.c:13:26: error: 'strcmp' undeclared (first use in this function)
   13 |   qsort(s,n,sizeof(char),strcmp);
      |                          ^~~~~~
main.c:3:1: note: 'strcmp' is defined in header '<string.h>'; this is probably fixable by adding '#include <string.h>'
    2 | #include <math.h>
  +++ |+#include <string.h>
    3 | int main(void){
main.c:13:26: note: each undeclared identifier is reported only once for each function it appears in
   13 |   qsort(s,n,sizeof(char),strcmp);
      |                          ^~~~~~
main.c:16:10: error: implicit declaration of function 'strcmp' [-Wimplicit-function-declaration]
   16 |       if(strcmp(s[i],s[i-1])!=0){
      |          ^~~~~~
main.c:16:10: note: include '<string.h>' or provide a declaration of 'strcmp'
main.c:16:18: error: passing argument 1 of 'strcmp' makes pointer from integer without a cast [-Wint-conversion]
   16 |       if(strcmp(s[i],s[i-1])!=0){
      |                 ~^~~
      |                  |
      |                  char
main.c:16:18: note: expected 'const char *' but argument is of type 'char'
main.c:16:23: error: passing argument 2 of 'strcmp' makes pointer from integer without a cast [-Wint-conversion]
   16 |       if(strcmp(s[i],s[i-1])!=0){
      |                      ~^~~~~
      |                       |
      |                       char
main.c:16:23: note: expected 'const char *' but argument is of type 'char'
Language: C

#include <stdio.h>
#include <math.h>
int main (void){
  int n;
  int i;
  int sum=0;
    scanf("%d", &n);
    char s[n];
    for(i=0;i<n;i++){
        scanf("%s",s[i]);
    }
    qsort(s,n,sizeof(int),cmp); 
   
  for(i=0;i<n-1;i++){
        if(cmp(s[i],s[i+1])!=0)
            sum++;
    } 
    printf("%d",k+1);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:12:5: error: implicit declaration of function 'qsort' [-Wimplicit-function-declaration]
   12 |     qsort(s,n,sizeof(int),cmp);
      |     ^~~~~
main.c:12:27: error: 'cmp' undeclared (first use in this function)
   12 |     qsort(s,n,sizeof(int),cmp);
      |                           ^~~
main.c:12:27: note: each undeclared identifier is reported only once for each function it appears in
main.c:15:12: error: implicit declaration of function 'cmp' [-Wimplicit-function-declaration]
   15 |         if(cmp(s[i],s[i+1])!=0)
      |            ^~~
main.c:18:17: error: 'k' undeclared (first use in this function)
   18 |     printf("%d",k+1);
      |                 ^
Language: C

#include<stdio.h>

int main(void){
  int n,i,j,kind=0;
  char str[20000][11];
  
  scanf("%d",&n);
  
  for(i=0;i<n;i++){
    scanf("%s",&str[i])
  }
  
  for(i=1;i<n;i++){
    for(j=i-i;j<=0;j--){
      if(strcmp(str[i],str[j])!=0){
        kind++; 
        break;
      }
    }
  }
  
  printf("%d",kind);
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:24: error: expected ';' before '}' token
   10 |     scanf("%s",&str[i])
      |                        ^
      |                        ;
   11 |   }
      |   ~                     
main.c:15:10: error: implicit declaration of function 'strcmp' [-Wimplicit-function-declaration]
   15 |       if(strcmp(str[i],str[j])!=0){
      |          ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strcmp'
    1 | #include<stdio.h>
  +++ |+#include <string.h>
    2 |
Language: C

#include <stdio.h>

int main(void)
{
  int n,i,j,count=0;
  
  scanf("%d",&n);
  
  char str[n][128];
  
  for(i=0;i<n;i++){
    scanf("%s",str[n]);
    count+=1;
    for(j=0;j<i;j++){
      ifI(str[n]==str[j]){
        count-=1;
        break;
      }
    }
  }
  
  printf("%d",count);
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:15:7: error: implicit declaration of function 'ifI' [-Wimplicit-function-declaration]
   15 |       ifI(str[n]==str[j]){
      |       ^~~
main.c:15:26: error: expected ';' before '{' token
   15 |       ifI(str[n]==str[j]){
      |                          ^
      |                          ;
Language: C

#include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i,n) for(int i=0;i<(n);++i)
#define repi(i,a,b) for(int i=int(a);i<int(b);++i)
#define all(x) (x).begin(), (x).end()
#define PI 3.14159265358979323846264338327950L
using namespace std;
typedef long long ll;
typedef long double ld;
int main() {
    int n;
    cin>>n;
    set<string> st;
    rep(i,n){
        string s;
        cin>>s;
        st.insert(s);
    }
    cout<<st.size()<<endl;
}

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

#include <stdio.h>

int main(void)
{
  int n,i,j,count=0;
  
  scanf("%d",&n);
  
  char str[n][128];
  
  for(i=0;i<n;i++){
    scanf("%s",str[n]);
    count+=1;
    for(j=0;j<i;J++){
      ifI(str[n]==str[j]){
        count-=1;
        break;
      }
    }
  }
  
  printf("%d",count);
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:14:17: error: 'J' undeclared (first use in this function)
   14 |     for(j=0;j<i;J++){
      |                 ^
main.c:14:17: note: each undeclared identifier is reported only once for each function it appears in
main.c:15:7: error: implicit declaration of function 'ifI' [-Wimplicit-function-declaration]
   15 |       ifI(str[n]==str[j]){
      |       ^~~
main.c:15:26: error: expected ';' before '{' token
   15 |       ifI(str[n]==str[j]){
      |                          ^
      |                          ;
Language: C

#include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i,n) for(int i=0;i<(n);++i)
#define repi(i,a,b) for(int i=int(a);i<int(b);++i)
#define all(x) (x).begin(), (x).end()
#define PI 3.14159265358979323846264338327950L
using namespace std;
typedef long long ll;
typedef long double ld;
int main() {
    int n;
    cin>>n;
    set<string> st;
    rep(i,n){
        string s;
        cin>>s;
        st.insert(s);
    }
    cout<<st.size();
}

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

#include <bits/stdc++.h> 

using namespace std;

set<string> st;

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

	while(n--){
      string s;
      cin >> s;
      
      st.push(s);
    }
  
  	cout << st.size() << endl;
  
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:15:10: error: 'class std::set<std::__cxx11::basic_string<char> >' has no member named 'push'
   15 |       st.push(s);
      |          ^~~~
Language: C++

#define rep(i,n) for(int i=0;i<(n);++i)
#define repi(i,a,b) for(int i=int(a);i<int(b);++i)
#define all(x) (x).begin(), (x).end()
#define PI 3.14159265358979323846264338327950L
using namespace std;
typedef long long ll;
typedef long double ld;
int main() {
    int n,cnt=0;
    cin>>n;
    vector<string> s(n);
    rep(i,n) cin>>s[i];
    sort(all(s));
    rep(i,n-1){
        if(s[i]!=s[i+1]) cnt++;
    }
    cout<<cnt<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:5: error: 'cin' was not declared in this scope
   10 |     cin>>n;
      |     ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #define rep(i,n) for(int i=0;i<(n);++i)
a.cc:11:5: error: 'vector' was not declared in this scope
   11 |     vector<string> s(n);
      |     ^~~~~~
a.cc:1:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
  +++ |+#include <vector>
    1 | #define rep(i,n) for(int i=0;i<(n);++i)
a.cc:11:12: error: 'string' was not declared in this scope
   11 |     vector<string> s(n);
      |            ^~~~~~
a.cc:1:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
  +++ |+#include <string>
    1 | #define rep(i,n) for(int i=0;i<(n);++i)
a.cc:11:20: error: 's' was not declared in this scope
   11 |     vector<string> s(n);
      |                    ^
a.cc:13:5: error: 'sort' was not declared in this scope; did you mean 'short'?
   13 |     sort(all(s));
      |     ^~~~
      |     short
a.cc:17:5: error: 'cout' was not declared in this scope
   17 |     cout<<cnt<<endl;
      |     ^~~~
a.cc:17:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:17:16: error: 'endl' was not declared in this scope
   17 |     cout<<cnt<<endl;
      |                ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | #define rep(i,n) for(int i=0;i<(n);++i)
Language: C++

int main()
{
    ll n;
    string tmp;
    cin >> n;

    unordered_map<string, ll> map;

    for(ll i = 0; i < n; ++i)
    {
        cin >> tmp;
        map[tmp]++;
    }

    cout << map.size() << "\n";
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:5: error: 'll' was not declared in this scope
    3 |     ll n;
      |     ^~
a.cc:4:5: error: 'string' was not declared in this scope
    4 |     string tmp;
      |     ^~~~~~
a.cc:5:5: error: 'cin' was not declared in this scope
    5 |     cin >> n;
      |     ^~~
a.cc:5:12: error: 'n' was not declared in this scope
    5 |     cin >> n;
      |            ^
a.cc:7:5: error: 'unordered_map' was not declared in this scope
    7 |     unordered_map<string, ll> map;
      |     ^~~~~~~~~~~~~
a.cc:7:31: error: 'map' was not declared in this scope
    7 |     unordered_map<string, ll> map;
      |                               ^~~
a.cc:9:11: error: expected ';' before 'i'
    9 |     for(ll i = 0; i < n; ++i)
      |           ^~
      |           ;
a.cc:9:19: error: 'i' was not declared in this scope
    9 |     for(ll i = 0; i < n; ++i)
      |                   ^
a.cc:11:16: error: 'tmp' was not declared in this scope
   11 |         cin >> tmp;
      |                ^~~
a.cc:15:5: error: 'cout' was not declared in this scope
   15 |     cout << map.size() << "\n";
      |     ^~~~
Language: C++

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

using namespace std;

#define debug(x) (cout << # x ": " << x << endl)
#define int long long int
#define repeat(n) for (int i = 0; i < n; ++i)
#define repeat2(n) for (int j = 0; j < n; ++j)
#define all(x) (x).begin(), (x).end()

#define MAX_SIZE (100001)

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

    set<string> se;

    repeat(n) {
        string s;
        cin >> s;

        se.insert(s);
    }

    cout << se.size;
    
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:36:10: error: invalid use of non-static member function 'std::set<_Key, _Compare, _Alloc>::size_type std::set<_Key, _Compare, _Alloc>::size() const [with _Key = std::__cxx11::basic_string<char>; _Compare = std::less<std::__cxx11::basic_string<char> >; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; size_type = long unsigned int]'
   36 |     cout << se.size;
      |     ~~~~~^~~~~~~~~~
In file included from /usr/include/c++/14/set:63,
                 from a.cc:7:
/usr/include/c++/14/bits/stl_set.h:421:7: note: declared here
  421 |       size() const _GLIBCXX_NOEXCEPT
      |       ^~~~
Language: Java

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws Exception {
        // Your code here!

       Scanner sc = new Scanner(System.in);
       int i = sc.nextInt();
       List<String> tinko = new ArrayList<>();

       for(int t = 0;t < i;t++){
           tinko.add(sc.next());
       }

       Long kosuu = tinko.stream().distinct().count();

       System.out.println(kosuu);

    }

Compiler output:
Main.java:21: error: reached end of file while parsing
    }
     ^
1 error
Language: C++

using namespace std;

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  int counter = 0;
  for (int i = 0; i < N; i++) {
    for (int j = 0; j <= i; j++) {
      if (vec.at(i) == vec.at(j)) {
        counter++;
        break;
      }
    }
  }
  cout << counter << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> N;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | using namespace std;
a.cc:6:3: error: 'vector' was not declared in this scope
    6 |   vector<string> vec(N);
      |   ^~~~~~
a.cc:1:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
  +++ |+#include <vector>
    1 | using namespace std;
a.cc:6:10: error: 'string' was not declared in this scope
    6 |   vector<string> vec(N);
      |          ^~~~~~
a.cc:1:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
  +++ |+#include <string>
    1 | using namespace std;
a.cc:6:18: error: 'vec' was not declared in this scope
    6 |   vector<string> vec(N);
      |                  ^~~
a.cc:7:9: error: expected ';' before 'S'
    7 |   string S;
      |         ^~
      |         ;
a.cc:9:12: error: 'S' was not declared in this scope
    9 |     cin >> S;
      |            ^
a.cc:21:3: error: 'cout' was not declared in this scope
   21 |   cout << counter << endl;
      |   ^~~~
a.cc:21:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:21:22: error: 'endl' was not declared in this scope
   21 |   cout << counter << endl;
      |                      ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | using namespace std;
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  it = str.begin();         // 先頭のイテレータを取得
  it = str.insert(it,vec.at(0));
  for (int i = 1; i < N; i++) {
    for (int j = 0; j < str.size(); j++) {
    if (vec.at(i) != str.at(j))
      it = str.begin();         // 先頭のイテレータを取得
      it = str.insert(it,vec.at(i));
  }
  cout << str.size() << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:14:3: error: 'it' was not declared in this scope; did you mean 'int'?
   14 |   it = str.begin();         // 先頭のイテレータを取得
      |   ^~
      |   int
a.cc:14:12: error: request for member 'begin' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   14 |   it = str.begin();         // 先頭のイテレータを取得
      |            ^~~~~
a.cc:15:12: error: request for member 'insert' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   15 |   it = str.insert(it,vec.at(0));
      |            ^~~~~~
a.cc:17:29: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   17 |     for (int j = 0; j < str.size(); j++) {
      |                             ^~~~
a.cc:18:26: error: request for member 'at' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |     if (vec.at(i) != str.at(j))
      |                          ^~
a.cc:19:16: error: request for member 'begin' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   19 |       it = str.begin();         // 先頭のイテレータを取得
      |                ^~~~~
a.cc:20:16: error: request for member 'insert' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   20 |       it = str.insert(it,vec.at(i));
      |                ^~~~~~
a.cc:22:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   22 |   cout << str.size() << endl;
      |               ^~~~
a.cc:23:2: error: expected '}' at end of input
   23 | }
      |  ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  str.insert(vec.at(0));
  for (int i = 0; i < N; i++) {
    for (int j = 0; j < str.size(); j++) {
    if (vec.at(i) != str.at(j))
      str.insert(vec.at(i));
  }
  cout << str.size() << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:14:7: error: request for member 'insert' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   14 |   str.insert(vec.at(0));
      |       ^~~~~~
a.cc:16:29: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   16 |     for (int j = 0; j < str.size(); j++) {
      |                             ^~~~
a.cc:17:26: error: request for member 'at' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   17 |     if (vec.at(i) != str.at(j))
      |                          ^~
a.cc:18:11: error: request for member 'insert' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |       str.insert(vec.at(i));
      |           ^~~~~~
a.cc:20:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   20 |   cout << str.size() << endl;
      |               ^~~~
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  str.push_back(std::string(vec.at(0)));
  for (int i = 0; i < N; i++) {
    for (int j = 0; j < str.size(); j++) {
    if (vec.at(i) == str.at(j))
      str.push_back(std::string(vec.at(i)));
  }
  cout << str.size() << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:14:7: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   14 |   str.push_back(std::string(vec.at(0)));
      |       ^~~~~~~~~
a.cc:16:29: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   16 |     for (int j = 0; j < str.size(); j++) {
      |                             ^~~~
a.cc:17:26: error: request for member 'at' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   17 |     if (vec.at(i) == str.at(j))
      |                          ^~
a.cc:18:11: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |       str.push_back(std::string(vec.at(i)));
      |           ^~~~~~~~~
a.cc:20:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   20 |   cout << str.size() << endl;
      |               ^~~~
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  str.push_back(vec.at(0));
  for (int i = 0; i < N; i++) {
    for (int j = 0; j < str.size(); j++) {
    if (vec.at(i) == str.at(j))
      str.push_back(vec.at(i));
  }
  cout << str.size() << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:14:7: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   14 |   str.push_back(vec.at(0));
      |       ^~~~~~~~~
a.cc:16:29: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   16 |     for (int j = 0; j < str.size(); j++) {
      |                             ^~~~
a.cc:17:26: error: request for member 'at' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   17 |     if (vec.at(i) == str.at(j))
      |                          ^~
a.cc:18:11: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |       str.push_back(vec.at(i));
      |           ^~~~~~~~~
a.cc:20:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   20 |   cout << str.size() << endl;
      |               ^~~~
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  for (int i = 0; i < N; i++) {
    if (str.rfind(vec.at(i)) == string::npos)
      str.push_back(vec.at(i));
  }
  cout << str.size() << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:15:13: error: request for member 'rfind' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   15 |     if (str.rfind(vec.at(i)) == string::npos)
      |             ^~~~~
a.cc:16:11: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   16 |       str.push_back(vec.at(i));
      |           ^~~~~~~~~
a.cc:18:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |   cout << str.size() << endl;
      |               ^~~~
Language: C++

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

int main() {
  int N;
  cin >> N;
  vector<string> vec(N);
  vector<string> str();
  string S;
  for (int i = 0; i < N; i++) {
    cin >> S;
    vec.at(i) = S;
  }
  for (int i = 0; i < N; i++) {
    if (str.find(vec.at(i)) == string::npos)
      str.push_back(vec.at(i));
  }
  cout << str.size() << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:21: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   vector<string> str();
      |                     ^~
a.cc:8:21: note: remove parentheses to default-initialize a variable
    8 |   vector<string> str();
      |                     ^~
      |                     --
a.cc:15:13: error: request for member 'find' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   15 |     if (str.find(vec.at(i)) == string::npos)
      |             ^~~~
a.cc:16:11: error: request for member 'push_back' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   16 |       str.push_back(vec.at(i));
      |           ^~~~~~~~~
a.cc:18:15: error: request for member 'size' in 'str', which is of non-class type 'std::vector<std::__cxx11::basic_string<char> >()'
   18 |   cout << str.size() << endl;
      |               ^~~~
Language: C++

#inclue<bits/stdc++.h>
using namespace std;
int main(){
  set<string>s;
  int n;
  cin >> n;
  while(n--){
    string l
    	cin >>l;
    s.insert(l);
  }
  cout << s.size();
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #inclue; did you mean #include?
    1 | #inclue<bits/stdc++.h>
      |  ^~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:4:3: error: 'set' was not declared in this scope
    4 |   set<string>s;
      |   ^~~
a.cc:1:1: note: 'std::set' is defined in header '<set>'; this is probably fixable by adding '#include <set>'
  +++ |+#include <set>
    1 | #inclue<bits/stdc++.h>
a.cc:4:7: error: 'string' was not declared in this scope
    4 |   set<string>s;
      |       ^~~~~~
a.cc:1:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
  +++ |+#include <string>
    1 | #inclue<bits/stdc++.h>
a.cc:4:14: error: 's' was not declared in this scope
    4 |   set<string>s;
      |              ^
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin >> n;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #inclue<bits/stdc++.h>
a.cc:8:11: error: expected ';' before 'l'
    8 |     string l
      |           ^~
      |           ;
a.cc:10:14: error: 'l' was not declared in this scope
   10 |     s.insert(l);
      |              ^
a.cc:12:3: error: 'cout' was not declared in this scope
   12 |   cout << s.size();
      |   ^~~~
a.cc:12:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

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

int main(){
  int N;
  int count = 0;
  cin >> N;
    
  vector<string> data(N);
  vector<string> Gdata(N);
  
  for(int i = 0;i < N ;i++){
    cin >> data.at(i);
  }
  
  for(int i = 0;i < N ;i++){
  	bool sameflag = false;

    for(int j = 0; j < count ; j++){
      if(data.at(i) == Gdata.at(j)){
        sameflag = true;
        break;
      }
    }
    if(sameflag)
      continue;
    Gdata.at(count) = data.at(i);
    count++;
  }

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

#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define REP(i,n) for(int i=1;i<n;i++)
#define rev(i,n) for(int i=n-1;i>=0;i--)
using namespace std;
int main(){
  int N;
  cin>>N;
  vector<string>A(N);
  set<string>S;
  rep(i,N){
    cin>>A[i];
    S.insent(A[i]);
  }
  cout<<S.size()<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:7: error: 'class std::set<std::__cxx11::basic_string<char> >' has no member named 'insent'; did you mean 'insert'?
   13 |     S.insent(A[i]);
      |       ^~~~~~
      |       insert
Language: C++

/* 
 * Project: AtCoder Beginners Contest 164 C - gacha
 * Author: toms74209200 <https://github.com/toms74209200>
 *
 * Created on 2020/07/07
 * Copyright (c) 2020 toms74209200
 * 
 * This software is released under the MIT License.
 * http://opensource.org/licenses/mit-license.php
 */
#include <cstdio>
#include <map>
using namespace std;

int n;
map<string, int> items;

void solve() {
    int num = items.size();
    printf("%d\n", num);
}

int main() {

    scanf("%d", &n);
    for (int i=0;i<n;i++) {
        char s[10];
        scanf("%s", s);
        items[(string)s]++;
    }

    solve();
}

Compiler output:
a.cc:16:5: error: 'string' was not declared in this scope
   16 | map<string, int> items;
      |     ^~~~~~
a.cc:13:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
   12 | #include <map>
  +++ |+#include <string>
   13 | using namespace std;
a.cc:16:16: error: template argument 1 is invalid
   16 | map<string, int> items;
      |                ^
a.cc:16:16: error: template argument 3 is invalid
a.cc:16:16: error: template argument 4 is invalid
a.cc: In function 'void solve()':
a.cc:19:21: error: request for member 'size' in 'items', which is of non-class type 'int'
   19 |     int num = items.size();
      |                     ^~~~
a.cc: In function 'int main()':
a.cc:29:16: error: 'string' was not declared in this scope
   29 |         items[(string)s]++;
      |                ^~~~~~
a.cc:29:16: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
a.cc:29:23: error: expected ']' before 's'
   29 |         items[(string)s]++;
      |                       ^
      |                       ]
Language: C

#include<stdio.h>
#include<string.h>
#include<stdlib.h>

int main(void){
    int n,ans=1;
    char s[n][11];
  	scanf("%d",&n);
    for(int i = 0;i < n;i++)scanf("%s",s[i]);
    qsort(s,n,11,strcmp);
    for(i = 1;i < n;i++) if(strcmp(s[i-1],s[i]))ans++;
    printf("%d",ans);
}


Compiler output:
main.c: In function 'main':
main.c:10:18: error: passing argument 4 of 'qsort' from incompatible pointer type [-Wincompatible-pointer-types]
   10 |     qsort(s,n,11,strcmp);
      |                  ^~~~~~
      |                  |
      |                  int (*)(const char *, const char *)
In file included from main.c:3:
/usr/include/stdlib.h:971:34: note: expected '__compar_fn_t' {aka 'int (*)(const void *, const void *)'} but argument is of type 'int (*)(const char *, const char *)'
  971 |                    __compar_fn_t __compar) __nonnull ((1, 4));
      |                    ~~~~~~~~~~~~~~^~~~~~~~
main.c:11:9: error: 'i' undeclared (first use in this function)
   11 |     for(i = 1;i < n;i++) if(strcmp(s[i-1],s[i]))ans++;
      |         ^
main.c:11:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
#include<stdlib.h>
#include<string.h>

typedef long long ll;

int main(){
    ll n,count=1;
    char s[n][11];
    scanf("%lld",&n);
    for(int i=0;i<n;i++) {scanf("%s",s[i]);
    qsort(s,n,11,strcmp);
    for(int i=0;i<n;i++){
        if(strcmp(s[i],s[i+1])!=0) count++;
    }
    printf("%lld",count);

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:12:18: error: passing argument 4 of 'qsort' from incompatible pointer type [-Wincompatible-pointer-types]
   12 |     qsort(s,n,11,strcmp);
      |                  ^~~~~~
      |                  |
      |                  int (*)(const char *, const char *)
In file included from main.c:2:
/usr/include/stdlib.h:971:34: note: expected '__compar_fn_t' {aka 'int (*)(const void *, const void *)'} but argument is of type 'int (*)(const char *, const char *)'
  971 |                    __compar_fn_t __compar) __nonnull ((1, 4));
      |                    ~~~~~~~~~~~~~~^~~~~~~~
main.c:19:1: error: expected declaration or statement at end of input
   19 | }
      | ^