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

#include<iostream>
using namespace std;
int main()
{
	int i,a,l,tt=0;
	cin>>a;
	int s[a+1],b[a+1]={0};
	for(i=1;i<=a;i++)
		cin>>s[i];
	for(i=1;i<=a;i++)
		for(l=1;l<=a-1;l++)
		{
			if(a[i]&&a[l]==0)
			{
				if(b[i]==b[l])
				{
					tt++;
					a[i]++;
					a[l]++;
				}
			}
		}
	cout<<tt;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:29: error: invalid types 'int[int]' for array subscript
   13 |                         if(a[i]&&a[l]==0)
      |                             ^
a.cc:13:35: error: invalid types 'int[int]' for array subscript
   13 |                         if(a[i]&&a[l]==0)
      |                                   ^
a.cc:18:42: error: invalid types 'int[int]' for array subscript
   18 |                                         a[i]++;
      |                                          ^
a.cc:19:42: error: invalid types 'int[int]' for array subscript
   19 |                                         a[l]++;
      |                                          ^
Language: C++

#include <stdio.h>

int main()
{
    int n, cnt, i;
    char ch[15];
    char tmp[15]="11";
    scanf("%d", &n);
    cnt=0; i=0;
    while (n--) {
        scanf("%s", ch);
        if (i==0) strcpy(tmp, ch); i++;
        if (strcmp(ch, tmp)!=0) cnt++;
        if (strcmp(ch, tmp)==0) strcpy(tmp, ch);
    }
    printf("%d\n", cnt+1);
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:19: error: 'strcpy' was not declared in this scope
   12 |         if (i==0) strcpy(tmp, ch); i++;
      |                   ^~~~~~
a.cc:2:1: note: 'strcpy' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <stdio.h>
  +++ |+#include <cstring>
    2 | 
a.cc:13:13: error: 'strcmp' was not declared in this scope
   13 |         if (strcmp(ch, tmp)!=0) cnt++;
      |             ^~~~~~
a.cc:13:13: note: 'strcmp' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
a.cc:14:13: error: 'strcmp' was not declared in this scope
   14 |         if (strcmp(ch, tmp)==0) strcpy(tmp, ch);
      |             ^~~~~~
a.cc:14:13: note: 'strcmp' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
a.cc:14:33: error: 'strcpy' was not declared in this scope
   14 |         if (strcmp(ch, tmp)==0) strcpy(tmp, ch);
      |                                 ^~~~~~
a.cc:14:33: note: 'strcpy' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
Language: C++

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

int main(){
  int N;
  
  cin >> N;
  
  int count = 1;
  vector<string> gacha(N);
  
  for(int i=0; i<N; i++){
    cin >> gacha.at(i);
  }
  
  sort(gacha.begin(), gacha.end());
  
  //sting first = gacha.at(0);
  int count = 1;

  for(int i=0; i<N-1; i++){
    if(gacha.at(i+1) != gacha.at(i)){
    count++;
    }
  }
  cout << count << endl;
}


  


Compiler output:
a.cc: In function 'int main()':
a.cc:19:7: error: redeclaration of 'int count'
   19 |   int count = 1;
      |       ^~~~~
a.cc:9:7: note: 'int count' previously declared here
    9 |   int count = 1;
      |       ^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int N;
string s;

void pre(){
  
  for (int i = 0; i < N; i++) {
    cin >> s;
    S.insert(s);
  }

  cout << S.size() << "\n";
  
}

int main(){
   ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cout << fixed << setprecision(15);

  cin >> N;
  unordered_set<string> S;
  pre();
  
}

Compiler output:
a.cc: In function 'void pre()':
a.cc:10:5: error: 'S' was not declared in this scope
   10 |     S.insert(s);
      |     ^
a.cc:13:11: error: 'S' was not declared in this scope
   13 |   cout << S.size() << "\n";
      |           ^
Language: Java

class Main
{
  Public static void main(String[] args)
  {
    int t;
    Scanner sc=new Scanner(System.in);
    Set<String> st=new HashSet<>();
    t=sc.nextInt();
    for(int i=0;i<t;i++)
    {
          st.add(sc.next());}
    System.out.println(st.size());
  }}

Compiler output:
Main.java:3: error: <identifier> expected
  Public static void main(String[] args)
        ^
1 error
Language: Java

import java.util.HashSet;
import java.util.Scanner;

public class hef {
	

	
	public static void main(String[] args) {

		
		Scanner s = new Scanner(System.in);
		HashSet<String> h = new HashSet<>();
		int n = s.nextInt();
		
		while(n--!=0) {
			h.add(s.next());
		}
		System.out.println(h.size());
		
		
	}
}

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

#include <iostream>
int main(){
using namespace std;
  int i,a,c,e=0,f=0;
  cin>>a;
  const int b=a;
  string abc[b];
  int d[a];
  for(i=0;i<a;i++){d[i]=0;}
 for(i=0;i<a;i++){cin>>abc[i];}
  for(i=0;i<a;i++){
    for(c=i+1;c<a;c++){
   if(abc[i]==abc[c]){d[i]=d[i]+1;}
 }
 }
  for(i=0;i<a;i++){
    f+=d[i];
    if(d[i]==0){e+=1;}}
cout<<(2a-f-e);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:19:8: error: unable to find numeric literal operator 'operator""a'
   19 | cout<<(2a-f-e);
      |        ^~
Language: C++

#include <iostream>
int main(){
using namespace std;
  int a,c=0;
  cin>>a;
  const int b=a;
  string abc[b];
 for(int i=0;i<a;i++){
   cin>>abc[i];
 }
  for(i=0;i<a;i++){
    if(a!=c){
      for(int c=i+1;c<a;c++){
   if(abc[i]==abc[c]){c++;}
 }}
   
 }
cout<<c;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:7: error: 'i' was not declared in this scope
   11 |   for(i=0;i<a;i++){
      |       ^
Language: C++

#include <iostream>
#include <set>

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

Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: 'set' was not declared in this scope
    6 |   set<string> st;
      |   ^~~
a.cc:6:3: note: suggested alternatives:
In file included from /usr/include/c++/14/set:63,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_set.h:96:11: note:   'std::set'
   96 |     class set
      |           ^~~
/usr/include/c++/14/set:87:13: note:   'std::pmr::set'
   87 |       using set = std::set<_Key, _Cmp, polymorphic_allocator<_Key>>;
      |             ^~~
a.cc:6:7: error: 'string' was not declared in this scope
    6 |   set<string> st;
      |       ^~~~~~
a.cc:6:7: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
                 from /usr/include/c++/14/ios:40,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
In file included from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44:
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:6:15: error: 'st' was not declared in this scope; did you mean 'std'?
    6 |   set<string> st;
      |               ^~
      |               std
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 |   cin>>n;
      |   ^~~
      |   std::cin
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:9:11: error: expected ';' before 's'
    9 |     string s;
      |           ^~
      |           ;
a.cc:10:10: error: 's' was not declared in this scope
   10 |     cin>>s;
      |          ^
a.cc:14:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   14 |   cout<<st.size();
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: Java

public class Main{
  public static void main(String[] args){
  	Scanner scn = new Scanner(System.in);
	    int n = scn.nextInt();
	    scn.nextLine();
	    String []arr = new String[n];
	    Map<String,Integer> map = new HashMap<String,Integer>();
	    for(int i=0;i<n;i++){
	      arr[i] = scn.nextLine();
	      if(map.containsKey(arr[i]))
	    	  map.put(arr[i], map.get(arr[i])+1);
	      else
	    	  map.put(arr[i],1);
	    }
	    int count = 0;
	    for(String s:map.keySet())
	    	count++;
	    System.out.println(count);
  }
}

Compiler output:
Main.java:3: error: cannot find symbol
  	Scanner scn = new Scanner(System.in);
  	^
  symbol:   class Scanner
  location: class Main
Main.java:3: error: cannot find symbol
  	Scanner scn = new Scanner(System.in);
  	                  ^
  symbol:   class Scanner
  location: class Main
Main.java:7: error: cannot find symbol
	    Map<String,Integer> map = new HashMap<String,Integer>();
	    ^
  symbol:   class Map
  location: class Main
Main.java:7: error: cannot find symbol
	    Map<String,Integer> map = new HashMap<String,Integer>();
	                                  ^
  symbol:   class HashMap
  location: class Main
4 errors
Language: C++

#include <iostream>
#include <unordered_map>
#include <string>
int main() {
  unordered_map<string, int> m;
  int n;
  string s;
  std::cin >> n;
  while(n > 0) {
    std::cin >> s;
    if (m.find(s)) {
      m[s] += 1;
    } else {
      m[s] = 1;
    }
    n--;
  }
  return m.size();
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'unordered_map' was not declared in this scope
    5 |   unordered_map<string, int> m;
      |   ^~~~~~~~~~~~~
a.cc:5:3: note: suggested alternatives:
In file included from /usr/include/c++/14/unordered_map:41,
                 from a.cc:2:
/usr/include/c++/14/bits/unordered_map.h:109:11: note:   'std::unordered_map'
  109 |     class unordered_map
      |           ^~~~~~~~~~~~~
/usr/include/c++/14/unordered_map:67:13: note:   'std::pmr::unordered_map'
   67 |       using unordered_map
      |             ^~~~~~~~~~~~~
a.cc:5:17: error: 'string' was not declared in this scope
    5 |   unordered_map<string, int> m;
      |                 ^~~~~~
a.cc:5:17: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
                 from /usr/include/c++/14/ios:40,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
In file included from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44:
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:5:25: error: expected primary-expression before 'int'
    5 |   unordered_map<string, int> m;
      |                         ^~~
a.cc:7:9: error: expected ';' before 's'
    7 |   string s;
      |         ^~
      |         ;
a.cc:10:17: error: 's' was not declared in this scope
   10 |     std::cin >> s;
      |                 ^
a.cc:11:9: error: 'm' was not declared in this scope
   11 |     if (m.find(s)) {
      |         ^
a.cc:18:10: error: 'm' was not declared in this scope
   18 |   return m.size();
      |          ^
Language: C++

#include <iostream>
#include <unordered_map>
int main() {
  unordered_map<string, int> m;
  int n;
  string s;
  std::cin >> n;
  while(n > 0) {
    std::cin >> s;
    if (m.find(s)) {
      m[s] += 1;
    } else {
      m[s] = 1;
    }
    n--;
  }
  return m.size();
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'unordered_map' was not declared in this scope
    4 |   unordered_map<string, int> m;
      |   ^~~~~~~~~~~~~
a.cc:4:3: note: suggested alternatives:
In file included from /usr/include/c++/14/unordered_map:41,
                 from a.cc:2:
/usr/include/c++/14/bits/unordered_map.h:109:11: note:   'std::unordered_map'
  109 |     class unordered_map
      |           ^~~~~~~~~~~~~
/usr/include/c++/14/unordered_map:67:13: note:   'std::pmr::unordered_map'
   67 |       using unordered_map
      |             ^~~~~~~~~~~~~
a.cc:4:17: error: 'string' was not declared in this scope
    4 |   unordered_map<string, int> m;
      |                 ^~~~~~
a.cc:4:17: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
                 from /usr/include/c++/14/ios:40,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
In file included from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44:
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:4:25: error: expected primary-expression before 'int'
    4 |   unordered_map<string, int> m;
      |                         ^~~
a.cc:6:9: error: expected ';' before 's'
    6 |   string s;
      |         ^~
      |         ;
a.cc:9:17: error: 's' was not declared in this scope
    9 |     std::cin >> s;
      |                 ^
a.cc:10:9: error: 'm' was not declared in this scope
   10 |     if (m.find(s)) {
      |         ^
a.cc:17:10: error: 'm' was not declared in this scope
   17 |   return m.size();
      |          ^
Language: C

#include<iostream>
#include<iomanip>
#include<cmath>
#include<string>
#include<vector>
#include<algorithm>
#include<map>
#include<set>
#include<queue>
#include<stack>
using namespace std;
typedef long long ll;
#define fi first
#define se second
#define mp make_pair
const int inf=1e9+7;
const ll mod=1e9+7;

int main() {
    int N;
    cin>>N;
    set<string> ans;
    string tmp;
    for(int i=0;i<N;++i){
        cin>>tmp;
        ans.insert(tmp);
    }
    cout<<ans.size()<<endl;
}



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

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

int main() {
    int n;
    cin >> n;
    vector<string> data(n);
    for (int i = 0; i < n; i++) {
        cin >> data.at(i);
    }
    sort(data.begin(), data.end());

    vector<string> vec;
    vec.push_back(data.at(0));
    for (int i = 0; i < n - 1; i++) {
        if (data.at(i) != data.at(i + 1)) {
            vec.push_back(data.at(i + 1));
        }
    }
    cout << vec.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 <iostream>
#include <string>

class HashList
{
private:
	struct HashNode
	{
		int val;
		HashNode *next;
	};

	HashNode *head;

public:
	HashList() {
		head = NULL;
	}

	void appendNode(int);
	void displayList();
	int countNode();
};

void HashList::appendNode(int num) {
	HashNode *newNode;
	HashNode *nodePtr;

	newNode = new HashNode;
	newNode->val = num;
	newNode->next = NULL;

	if (!head) {
		head = newNode;
	}
	else {
		nodePtr = head;
		if (nodePtr->val == num) {
			return;
		}
		while (nodePtr->next) {
			nodePtr = nodePtr->next;
			if (nodePtr->val == num) {
				return;
			}
		}
		nodePtr->next = newNode;
	}
}

void HashList::displayList() {
	HashNode *nodePtr = head;
	std::cout << "List" << std::endl;
	std::cout << "-----" << std::endl;
	if (!head) {
		std::cout << "Empty" << std::endl;
	}
	else {
		nodePtr = head;
		std::cout << nodePtr->val << std::endl;
		while (nodePtr->next) {
			nodePtr = nodePtr->next;
			std::cout << nodePtr->val << std::endl;
		}
	}
	std::cout << "-----" << std::endl;
}

int HashList::countNode() {
	HashNode *nodePtr = head;
	int count = 0;
	if (!head) {
	}
	else {
		nodePtr = head;
		count++;
		while (nodePtr->next) {
			nodePtr = nodePtr->next;
			count++;
		}
	}
	return count;
}

int main()
{
	HashList List;
	int N;
	std::cin >> N;
	//List.displayList();
	for(int n = 0; n < N; n++){
		std::string str;
		std::cin >> str;
		if (str == "0") {
			break;
		}
		else {
			List.appendNode(std::hash<std::string>()(str));
			//List.displayList();
		}
	}
	std::cout << List.countNode() << std::endl;

Compiler output:
a.cc: In function 'int main()':
a.cc:102:52: error: expected '}' at end of input
  102 |         std::cout << List.countNode() << std::endl;
      |                                                    ^
a.cc:86:1: note: to match this '{'
   86 | {
      | ^
Language: C

#include <iostream>
#include <vector>
#include <string>
using namespace std;
int main(){
    int num,sum=0;
    string b[100];
    cin>>num;
    vector<string>a;
        for (int i=0;i<num;i++){
            cin>>b[i];
            a.push_back(b[i]);
        }
    sort(a.begin(),a.end());
    for (int i=0; i<num; i++) {
        if (a[i]==a[i+1]){
            sum++;
        }
    }
    
    cout<<num-sum;
  
      return 0;
}


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

#include <iostream>
#include <vector>
#include <string>
using namespace std;
int main(){
    int num,sum=0;
    string b[100];
    cin>>num;
    vector<string>a;
        for (int i=0;i<num;i++){
            cin>>b[i];
            a.push_back(b[i]);
        }
    sort(a.begin(),a.end());
    for (int i=0; i<num; i++) {
        if (a[i]==a[i+1]){
            sum++;
        }
    }
    
    cout<<num-sum;
  
      return 0;
}

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

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  string tmp;
  std::vector<std::string> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>tmp;
    if(S.find(tmp)<0)S.push(tmp);
  }
  print("%d",S.size());
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: 'vector' is not a member of 'std'
    9 |   std::vector<std::string> S;
      |        ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:26: error: expected primary-expression before '>' token
    9 |   std::vector<std::string> S;
      |                          ^
a.cc:9:28: error: 'S' was not declared in this scope
    9 |   std::vector<std::string> S;
      |                            ^
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d",S.size());
      |   ^~~~~
      |   printf
Language: C++

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  string tmp;
  std::vector<string> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>tmp;
    if(S.find(tmp)<0)S.push(tmp);
  }
  print("%d",S.size());
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: 'vector' is not a member of 'std'
    9 |   std::vector<string> S;
      |        ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:21: error: expected primary-expression before '>' token
    9 |   std::vector<string> S;
      |                     ^
a.cc:9:23: error: 'S' was not declared in this scope
    9 |   std::vector<string> S;
      |                       ^
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d",S.size());
      |   ^~~~~
      |   printf
Language: C++

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  string tmp;
  std::vector<string> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>temp;
    if(S.find(tmp)<0)S.push(tmp);
  }
  print("%d",S.size());
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: 'vector' is not a member of 'std'
    9 |   std::vector<string> S;
      |        ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:21: error: expected primary-expression before '>' token
    9 |   std::vector<string> S;
      |                     ^
a.cc:9:23: error: 'S' was not declared in this scope
    9 |   std::vector<string> S;
      |                       ^
a.cc:13:10: error: 'temp' was not declared in this scope; did you mean 'tmp'?
   13 |     cin>>temp;
      |          ^~~~
      |          tmp
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d",S.size());
      |   ^~~~~
      |   printf
Language: C++

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  string temp;
  std::vector<string> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>temp;
    if(S.find(temp)<0)S.push(tmp);
  }
  print("%d."S.size());
  return o;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: 'vector' is not a member of 'std'
    9 |   std::vector<string> S;
      |        ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:21: error: expected primary-expression before '>' token
    9 |   std::vector<string> S;
      |                     ^
a.cc:9:23: error: 'S' was not declared in this scope
    9 |   std::vector<string> S;
      |                       ^
a.cc:14:30: error: 'tmp' was not declared in this scope; did you mean 'temp'?
   14 |     if(S.find(temp)<0)S.push(tmp);
      |                              ^~~
      |                              temp
a.cc:16:9: error: unable to find string literal operator 'operator""S' with 'const char [4]', 'long unsigned int' arguments
   16 |   print("%d."S.size());
      |         ^~~~~~
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d."S.size());
      |   ^~~~~
      |   printf
a.cc:17:10: error: 'o' was not declared in this scope
   17 |   return o;
      |          ^
Language: C++

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  string temp;
  vector<string> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>temp;
    if(S.find(temp)<0)S.push(tmp);
  }
  print("%d."S.size());
  return o;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:3: error: 'vector' was not declared in this scope
    9 |   vector<string> S;
      |   ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:16: error: expected primary-expression before '>' token
    9 |   vector<string> S;
      |                ^
a.cc:9:18: error: 'S' was not declared in this scope
    9 |   vector<string> S;
      |                  ^
a.cc:14:30: error: 'tmp' was not declared in this scope; did you mean 'temp'?
   14 |     if(S.find(temp)<0)S.push(tmp);
      |                              ^~~
      |                              temp
a.cc:16:9: error: unable to find string literal operator 'operator""S' with 'const char [4]', 'long unsigned int' arguments
   16 |   print("%d."S.size());
      |         ^~~~~~
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d."S.size());
      |   ^~~~~
      |   printf
a.cc:17:10: error: 'o' was not declared in this scope
   17 |   return o;
      |          ^
Language: C++

#include<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  String temp;
  vector<String> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>temp;
    if(S.find(temp)<0)S.push(tmp);
  }
  print("%d."S.size());
  return o;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'String' was not declared in this scope
    8 |   String temp;
      |   ^~~~~~
a.cc:9:3: error: 'vector' was not declared in this scope
    9 |   vector<String> S;
      |   ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:18: error: 'S' was not declared in this scope
    9 |   vector<String> S;
      |                  ^
a.cc:13:10: error: 'temp' was not declared in this scope; did you mean 'tm'?
   13 |     cin>>temp;
      |          ^~~~
      |          tm
a.cc:14:30: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   14 |     if(S.find(temp)<0)S.push(tmp);
      |                              ^~~
      |                              tm
a.cc:16:9: error: unable to find string literal operator 'operator""S' with 'const char [4]', 'long unsigned int' arguments
   16 |   print("%d."S.size());
      |         ^~~~~~
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d."S.size());
      |   ^~~~~
      |   printf
a.cc:17:10: error: 'o' was not declared in this scope
   17 |   return o;
      |          ^
Language: C++

#inclde<stdio.h>
#include<string>
#include<iostream>
using namespace std;
int main(){
  int N;
  int i;
  String temp;
  std::vector<String> S;
  scanf("%d",&N);
  S.resize(N);
  for(i=0;i<N;i++){
    cin>>tmp;
    if(S.find(tem)<0)S.push(tmp);
  }
  print("%d."S.size());
  return o;
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #inclde; did you mean #include?
    1 | #inclde<stdio.h>
      |  ^~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:8:3: error: 'String' was not declared in this scope
    8 |   String temp;
      |   ^~~~~~
a.cc:9:8: error: 'vector' is not a member of 'std'
    9 |   std::vector<String> S;
      |        ^~~~~~
a.cc:4:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    3 | #include<iostream>
  +++ |+#include <vector>
    4 | using namespace std;
a.cc:9:23: error: 'S' was not declared in this scope
    9 |   std::vector<String> S;
      |                       ^
a.cc:13:10: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   13 |     cin>>tmp;
      |          ^~~
      |          tm
a.cc:14:15: error: 'tem' was not declared in this scope; did you mean 'tm'?
   14 |     if(S.find(tem)<0)S.push(tmp);
      |               ^~~
      |               tm
a.cc:16:9: error: unable to find string literal operator 'operator""S' with 'const char [4]', 'long unsigned int' arguments
   16 |   print("%d."S.size());
      |         ^~~~~~
a.cc:16:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   16 |   print("%d."S.size());
      |   ^~~~~
      |   printf
a.cc:17:10: error: 'o' was not declared in this scope
   17 |   return o;
      |          ^
Language: C

#include "bits/stdc++.h"
using namespace std;
signed main()
{
	int n;
	cin >> n;
	set<string> a;
	string s;
	for(int i = 0; i < n; ++i)
	{
		cin >> s;
		a.insert(s);
	}
	cout << a.size() << "\n";	
}


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>
#include <string.h>

int main(){
  int N,Count = 0;
  scanf("%d",&N);
  char str[N][11];
  
  for(i = 0;N > i; i++){
	scanf("%s",str[i]);
  }
  
  for(i = 0; N > i; i++){
    for(j = 0; i > j; j++){
	  if(0 == strcmp(str[i],str[j])){
        Count++;
        continue;
      }
    }
  }
  
  printf("%d\n",N-Count);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:7: error: 'i' undeclared (first use in this function)
    9 |   for(i = 0;N > i; i++){
      |       ^
main.c:9:7: note: each undeclared identifier is reported only once for each function it appears in
main.c:14:9: error: 'j' undeclared (first use in this function)
   14 |     for(j = 0; i > j; j++){
      |         ^
Language: C

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

int main() {
	int n;
	cin >> n;
	
	set<string> ans;
	
	for (int i = 0; i < n; i++) {
		string s;
		cin >> s;
		ans.insert(s);
	}
	
	cout << ans.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>
#include<string.h>
#include<stdlib.h>

int main(){
  
  int n;
  int count = 0;
  scanf("%d",&n);

  char S[n][11];
  
  for(int i=0; i<n; i++){
    scanf("%s",&S[i]);
  }
  qsort(S,n,11,strcmp);

  for(int i=1; i<n; i++){
    if( strcmp(S[n-1],S[n])<0) ){
      count ++;
    }
  }

  printf("%d",count);

  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:16:16: error: passing argument 4 of 'qsort' from incompatible pointer type [-Wincompatible-pointer-types]
   16 |   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:19:32: error: expected statement before ')' token
   19 |     if( strcmp(S[n-1],S[n])<0) ){
      |                                ^
Language: C

#include<bits/stdc++.h>
using namespace std;
#define FAST ios_base::sync_with_stdio(false);cin.tie(NULL);
#define time_taken_start int begtime = clock();
#define time_taken_end int endtime = clock(); \
cerr << "\n\n" << "Time elapsed: " << \
(endtime - begtime)*1000/CLOCKS_PER_SEC << " ms\n\n"; \
return 0;
#define ll long long int
#define ull unsigned long long int
#define ld long double
#define mod 998244353
#define inf 1000000000000000007
#define eps 0.0000000001
#define pi acosl(-1)
#define pdd pair<ld,ld>
#define pll pair<ll,ll>
#define ff first
#define ss second
#define vpl vector<pll>
#define vll vector<ll>
#define mseti multiset <ll>
#define msetd multiset <ll,greater<ll>>
#define pb push_back
#define pf push_front
#define lb lower_bound
#define ub upper_bound 
#define stp fixed<<setprecision(20)
#define endl '\n'
set<string> s;
void solve()
{
	ll n;
	cin>>n;
	string str;
	for(ll i=0;i<n;i++)
	{
		cin>>str;
		s.insert(str);
	}
	cout<<s.size();
}
int main()
{
    FAST
    #ifdef ayk_16
    freopen("input.txt","rt",stdin);
    freopen("output.txt","wt",stdout);
    #endif
    ll t=1;
    //cin>>t;
    for(ll i=0;i<t;i++)
    {
        //cout<<"Case #"<<i+1<<": ";
        solve();
    }
}

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<stdio.h>
#include<string.h>
#include<stdlib.h>

void swap(char *str1, char *str2) {
  char *tmp;
  if (strcmp(str1, str2)) {
    tmp = str1;
    str1 = str2;
    str2 = tmp;
  }
}

int main(void) {
  int count, i, j, duplication = 0;
  char kuzi[1000][10];



  if (scanf("%d", &count));
  for (i = 0; i < count; i++) {
    kuzi[i] = (char *)malloc(10 * sizeof(char));
  }
  for (i = 0; i < count; i++) {
    if(scanf("%s", kuzi[i]));
  }

  for (i = 0; i < count; i++) {
    for (j = count - 1; j >= i; j--) {
      swap(kuzi[i], kuzi[j]);
    }
  }

  for (i = 0; i < count - 1; i++) {
    if (strcmp(kuzi[i], kuzi[i + 1]) == 0) {
      duplication++;
    } 
  }
  printf("%d", count - duplication);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:22:13: error: assignment to expression with array type
   22 |     kuzi[i] = (char *)malloc(10 * sizeof(char));
      |             ^
Language: C

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

int main() {
  int N, count = 0, j;
  string Si;
  vector<string> list;
  
  cin >> N;
  for(int i = 0; i < N; i++){
    cin >> Si;
    for(j = 0; j < count; j++){
    	if(list[j] == Si)break;
    }
    if(j == count){
      count++;
      list.push_back(Si);
    }
      
  }
  cout << count << 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 <bits/stdc++.h>
#define ll long long
#define pll pair<ll, ll>
using namespace std;
const ll maxn = 1e6 + 7;
const ll mod = 1e9 + 7;
ll q, t, n, m, k, ans;
priority_queue<ll> pr;
string s, ss[maxn], str;
void sol()
{
    cin >> n;
    for(int i = 0; i < n; i ++)
        cin >> ss[i];
    sort(ss, ss+n);
    ans = 0;
    for(int i = 0; i < n; i ++)
    {
        ++ans;
        while(ss[i] == ss[i+1] && i + 1 < n)
            ++i;
    }
    cout << ans;
}
int main()
{
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    sol();
}


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;

#define il inline
#define re register
#define Rep(i, s, e) for (re int i = s; i <= e; ++i)
#define Dep(i, s, e) for (re int i = s; i >= e; --i)
#define file(a) freopen(#a".in", "r", stdin), freopen(#a".out", "w", stdout)

il int read() {
    int x = 0; bool f = true; char c = getchar();
    while (c < '0' || c > '9') {if (c == '-') f = false; c = getchar();}
    while (c >= '0' && c <= '9') x = (x << 1) + (x << 3) + (c ^ 48), c = getchar();
    return f ? x : -x;
}

map <string, bool> M;

int n, ans;

int main() {
    n = read();
    while (n--) {
        string s;
        cin >> s;
        if (!M[s]) ++ans, M[s] = true;
    }
    printf("%d", ans);
    return 0;
}

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

import javax.print.DocFlavor;
import java.awt.*;
import java.io.PrintWriter;
import java.lang.reflect.Array;
import java.math.BigInteger;
import java.util.*;
import java.util.List;

public class Main {

    static String br = System.getProperty("line.separator");
    static Scanner sc = new Scanner(System.in);
    static PrintWriter out = new PrintWriter(System.out);

    public static void main(String[] args) {
        int N = nextInt();
        Set<String> set = new HashSet<>();
        for(int i=0; i<N; i++){
            set.add(next());
        }
        println(set.size());
    }

    static int nextInt() {
        return Integer.parseInt(next());
    }

    static Long nextLong() {
        return Long.parseLong(next());
    }

    static String next() {
        return sc.next();
    }

    static String nextLine(){
        return sc.nextLine();
    }

    static void println(Object o) {
        out.println(o);
        out.flush();
    }

    static void print(Object o) {
        PrintWriter out = new PrintWriter(System.out);
        out.print(o);
        out.flush();
    }
}


Compiler output:
main.c:1:1: error: unknown type name 'import'
    1 | import javax.print.DocFlavor;
      | ^~~~~~
main.c:1:13: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    1 | import javax.print.DocFlavor;
      |             ^
main.c:2:1: error: unknown type name 'import'
    2 | import java.awt.*;
      | ^~~~~~
main.c:2:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    2 | import java.awt.*;
      |            ^
main.c:3:1: error: unknown type name 'import'
    3 | import java.io.PrintWriter;
      | ^~~~~~
main.c:3:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    3 | import java.io.PrintWriter;
      |            ^
main.c:4:1: error: unknown type name 'import'
    4 | import java.lang.reflect.Array;
      | ^~~~~~
main.c:4:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    4 | import java.lang.reflect.Array;
      |            ^
main.c:5:1: error: unknown type name 'import'
    5 | import java.math.BigInteger;
      | ^~~~~~
main.c:5:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    5 | import java.math.BigInteger;
      |            ^
main.c:6:1: error: unknown type name 'import'
    6 | import java.util.*;
      | ^~~~~~
main.c:6:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    6 | import java.util.*;
      |            ^
main.c:7:1: error: unknown type name 'import'
    7 | import java.util.List;
      | ^~~~~~
main.c:7:12: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    7 | import java.util.List;
      |            ^
main.c:9:1: error: unknown type name 'public'
    9 | public class Main {
      | ^~~~~~
main.c:9:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'Main'
    9 | public class Main {
      |              ^~~~
Language: C++

#include<iostream>
#include<string>
#include<algorithm>
using namespace std;
string str;
unsigned long long int a[10010];
unsigned long long int hash()
{
	int len=str.size();
	unsigned long long int x=0;
	for(int i=0;i<len;i++)
	{
		x=x*131+str[i];
	}
	return x;
}
int main()
{
	int n,ans=1;
	cin>>n;
	for(int i=1;i<=n;i++)
	{
		cin>>str;
		a[i]=hash();
	}
	sort(a+1,a+n+1);
	for(int i=2;i<=n;i++)
	{
		if(a[i]!=a[i-1])
		{
			ans++;
		}
	}
	cout<<ans<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:22: error: reference to 'hash' is ambiguous
   24 |                 a[i]=hash();
      |                      ^~~~
In file included from /usr/include/c++/14/string_view:50,
                 from /usr/include/c++/14/bits/basic_string.h:47,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/functional_hash.h:59:12: note: candidates are: 'template<class _Tp> struct std::hash'
   59 |     struct hash;
      |            ^~~~
a.cc:7:24: note:                 'long long unsigned int hash()'
    7 | unsigned long long int hash()
      |                        ^~~~
Language: C++

#include<iostream>
#include<string>
#include<algorithm>
using namespace std;
string str;
unsigned long long a[10010];
unsigned long long hash()
{
	int len=str.size();
	unsigned long long x=0;
	for(int i=0;i<len;i++)
	{
		x=x*131+str[i];
	}
	return x;
}
int main()
{
	int n,ans=1;
	cin>>n;
	for(int i=1;i<=n;i++)
	{
		cin>>str;
		a[i]=hash();
	}
	sort(a+1,a+n+1);
	for(int i=2;i<=n;i++)
	{
		if(a[i]!=a[i-1])
		{
			ans++;
		}
	}
	cout<<ans<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:22: error: reference to 'hash' is ambiguous
   24 |                 a[i]=hash();
      |                      ^~~~
In file included from /usr/include/c++/14/string_view:50,
                 from /usr/include/c++/14/bits/basic_string.h:47,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/functional_hash.h:59:12: note: candidates are: 'template<class _Tp> struct std::hash'
   59 |     struct hash;
      |            ^~~~
a.cc:7:20: note:                 'long long unsigned int hash()'
    7 | unsigned long long hash()
      |                    ^~~~
Language: C

#include<bits/stdc++.h>
using namespace std;
int main()
{
	int n;
	cin>>n;
	set<string> s;
	for(int i=0;i<n;i++)
	{
		string letters;
		cin>>letters;
		s.insert(letters);
	}
	cout<<s.size();
	
	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<bits/stdc++.h>
using namespace std;
 
int main()
{
    int N;
    scanf("%d", &N);
    char str[200001][11];
 
 
    getchar();
    for(int i=0; i<N; i++)
        gets(str[i]);
 
 
    int a[N];
    for(int i=0; i<N; i++)
        a[i]=1;
 
    for(int i=0; i<N-1; i++)
    {
        if(a[i]==1)
        {
           for(int j=i+1; j<N; j++) {
                if(strcmp(str[i], str[j])==0)
                    a[j]=0;
            }
 
        }
 
    }
    int cnt=0;
    for(int i=0; i<N; i++)
        cnt += a[i];
    cout << cnt << endl;
 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   13 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C

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

int main() {
    ll N;
    scanf("%lld",&N);
    char s[200000][10];
    rep(i,N){
        scanf("%s",&s[i][0]);
    }
    ll count=0;
    rep(i,N){
        if(s[i][0]!='\0'){
            rep2(j,i+1,N){
                int strcount=0;
                rep(k,10){
                    if(s[i][k]==s[j][k]){
                        strcount++;
                    }
                }
                if(strcount==10){
                    s[j][0]='\0';
                }
            }
            count++;
        }
    }
    printf("%lld",count);
    return 0;
}

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>
#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    int N,i,j;
    int cnt=0;
    cin >> N;
    char str[N][11];
    getchar();
    for(int i=0; i<N; i++)
    {
        gets(str[i]);
    }
    int a[N];
    for(int i=0; i<N; i++)
    {
        a[i]=1;
    }
    for(i=0; i<N-1; i++)
    {

        if(a[i]==1)
        {
            for(int j=i+1; j<N; j++)
            {
                if(strcmp(str[i],str[j])==0)
                {
                    a[j]=0;
                }

            }
        }
    }
    for(int i=0; i<N; i++)
    {
        cnt+=a[i];
    }
    cout<< cnt << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   14 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C++

#include<bits/stdc++.h>
#include<iostream>
using namespace std;
int main()
{
    int N,i,j;
    int cnt=0;
    cin >> N;
    char str[N][11];
    getchar();
    for(int i=0; i<N; i++)
    {
        gets(str[i]);
    }
    int a[N];
    for(int i=0; i<N; i++)
    {
        a[i]=1;
    }
    for(i=0; i<N-1; i++)
    {

        if(a[i]==1)
        {
            for(int j=i+1; j<N; j++)
            {
                if(strcmp(str[i],str[j])==0)
                {
                    a[j]=0;
                }

            }
        }
    }
    for(int i=0; i<N; i++)
    {
        cnt+=a[i];
    }
    cout<< cnt << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   13 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    int N,i,j;
    int cnt=0;
    cin >> N;
    char str[N][11];
    getchar();
    for(int i=0; i<N; i++)
    {
        gets(str[i]);
    }
    int a[N];
    for(int i=0; i<N; i++)
    {
        a[i]=1;
    }
    for(i=0; i<N-1; i++)
    {

        if(a[i]==1)
        {
            for(int j=i+1; j<N; j++)
            {
                if(strcmp(str[i],str[j])==0)
                {
                    a[j]=0;
                }

            }
        }
    }
    for(int i=0; i<N; i++)
    {
        cnt+=a[i];
    }
    cout<< cnt << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   12 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C++

#include<iostream>
#include<stdio.h>
#include<string.h>
using namespace std;
 
int main()
{
    int N;
    scanf("%d", &N);
    char str[N][11];
 
 
    getchar();
    for(int i=0; i<N; i++)
        gets(str[i]);
 
 
    int a[N];
    for(int i=0; i<N; i++)
        a[i]=1;
 
    for(int i=0; i<N-1; i++)
    {
        if(a[i]==1)
        {
           for(int j=i+1; j<N; j++) {
                if(strcmp(str[i], str[j])==0)
                    a[j]=0;
            }
 
        }
 
    }
    int cnt=0;
    for(int i=0; i<N; i++)
        cnt += a[i];
    cout << cnt << endl;
 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   15 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C++

#include<bits/stdc++.h>
using namespace std;
 
int main()
{
    int N;
    scanf("%d", &N);
    char str[N][11];
 
 
    getchar();
    for(int i=0; i<N; i++)
        gets(str[i]);
 
 
    int a[N];
    for(int i=0; i<N; i++)
        a[i]=1;
 
    for(int i=0; i<N-1; i++)
    {
        if(a[i]==1)
        {
           for(int j=i+1; j<N; j++) {
                if(strcmp(str[i], str[j])==0)
                    a[j]=0;
            }
 
        }
 
    }
    int cnt=0;
    for(int i=0; i<N; i++)
        cnt += a[i];
    cout << cnt << endl;
 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:9: error: 'gets' was not declared in this scope; did you mean 'getw'?
   13 |         gets(str[i]);
      |         ^~~~
      |         getw
Language: C

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

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

	string kind[n];
	for (int i = 0; i < n; i++) {
		for (int j = i+1; j < n; j++) {
			if (s[i] == s[j]) {
				s.erase(s.begin() + j);
			}
		}
	}

	int ans = s.size();
	cout << ans << endl;
	return 0;
}


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

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


int32_t main(){
	#ifndef ONLINE_JUDGE
		freopen("input.txt","r",stdin);
		freopen("output.txt","w",stdout);
	#endif

	int n;
	cin>>n;
	string s;
	map<string,int> m;
	while(n--){
		cin>>s;
		m[s] = 1;
	}
	ans = 0;
	for(auto j:m) ans++;
		cout<<ans;


	return 0;
}

Compiler output:
a.cc: In function 'int32_t main()':
a.cc:22:9: error: 'ans' was not declared in this scope; did you mean 'abs'?
   22 |         ans = 0;
      |         ^~~
      |         abs
Language: C++

#include <iostream>
#include <set>
#include <string>
using namespace std;
int main()
{
  int N;
  cin >> N;
  set <string> gacha;
  for (int i = 0; i < N; i++) {
    string S;
    cin >> S;
    gacha.insert(S);
  }
  cout << gacha.size() << endl;
  return 0:
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:11: error: expected ';' before ':' token
   16 |   return 0:
      |           ^
      |           ;
a.cc:16:11: error: expected primary-expression before ':' token