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

#include<iostream>
int main(){
  int n,k;
  string a;
  cin>>n>>k;
  for(int i=0;i<k;i++){
    cin>>a;
    for(char j='1';j<=n;j++){
      for(int k=1;k<=a.size();k++){
        if(j==a[k]) continue;
        else cout<<j;
      }
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'string' was not declared in this scope
    4 |   string a;
      |   ^~~~~~
a.cc:4:3: 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:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |   cin>>n>>k;
      |   ^~~
      |   std::cin
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:7:10: error: 'a' was not declared in this scope
    7 |     cin>>a;
      |          ^
a.cc:11:14: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   11 |         else cout<<j;
      |              ^~~~
      |              std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

#include<iostream>
#include<string>
#include<algorithm>
#include<vector>
#include<iomanip>
#include<math.h>
#include<complex>
#include<queue>
#include<deque>
#include<stack>
#include<map>
#include<set>
#include<bitset>
#include<functional>
#include<assert.h>
#include<numeric>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> lpair;
const ll MOD = 1e9 + 7;
const ll INF = 1e18;
#define REP(i,m,n) for(int i=(int)(m) ; i < (int) (n) ; ++i )
#define rep(i,n) REP(i,0,n)
#define rREP(i,m,n) for(ll i = (m); i >= (n); i--)
#define ALL(c) (c).begin(), (c).end()
#define print(x) cout << (x) << endl;
#define printa(x,n) for(ll i = 0; i < n; i++){ cout << (x[i]) << " ";} cout<<endl;
int main(){
    cin.tie(0);
    ios::sync_with_stdio(false);
    
    int n,k;
    cin >> n >> k;
    bool ary[n];
    rep(i,n) ary[i] = false;
    rep(i,k)
    {
        int d;
        cin >> d;
        rep(j,d)
        {
            int a;
            cin >> a;
            a--;
            ary[a] = true;
        }
    }
    int ans = 0;
    rep(i,n) if (aryc[i]==false) ans++;
    cout << ans << endl;
    
}




Compiler output:
a.cc: In function 'int main()':
a.cc:49:18: error: 'aryc' was not declared in this scope; did you mean 'ary'?
   49 |     rep(i,n) if (aryc[i]==false) ans++;
      |                  ^~~~
      |                  ary
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 人数の入力
		int ninzu = sc.nextInt();
		int okasi = sc.nextInt();
      	int[] sum = new int[ninzu];
      	for (i=0; i<okasi; i++){
        	int c = sc.nextInt();
          	for (j=0; j<c; j++){
              sum[sc.nextInt()] = 1;
            }
        }
      	int ans = 0;
      	for (i=0; i+1<sum.size(); i++) {
          if (sum[i] != 1) {
            ans += 1;
          }
        }
		// 出力
		System.out.println(ans);
	}
}

Compiler output:
Main.java:9: error: cannot find symbol
      	for (i=0; i<okasi; i++){
      	     ^
  symbol:   variable i
  location: class Main
Main.java:9: error: cannot find symbol
      	for (i=0; i<okasi; i++){
      	          ^
  symbol:   variable i
  location: class Main
Main.java:9: error: cannot find symbol
      	for (i=0; i<okasi; i++){
      	                   ^
  symbol:   variable i
  location: class Main
Main.java:11: error: cannot find symbol
          	for (j=0; j<c; j++){
          	     ^
  symbol:   variable j
  location: class Main
Main.java:11: error: cannot find symbol
          	for (j=0; j<c; j++){
          	          ^
  symbol:   variable j
  location: class Main
Main.java:11: error: cannot find symbol
          	for (j=0; j<c; j++){
          	               ^
  symbol:   variable j
  location: class Main
Main.java:16: error: cannot find symbol
      	for (i=0; i+1<sum.size(); i++) {
      	     ^
  symbol:   variable i
  location: class Main
Main.java:16: error: cannot find symbol
      	for (i=0; i+1<sum.size(); i++) {
      	          ^
  symbol:   variable i
  location: class Main
Main.java:16: error: cannot find symbol
      	for (i=0; i+1<sum.size(); i++) {
      	                 ^
  symbol:   method size()
  location: variable sum of type int[]
Main.java:16: error: cannot find symbol
      	for (i=0; i+1<sum.size(); i++) {
      	                          ^
  symbol:   variable i
  location: class Main
Main.java:17: error: cannot find symbol
          if (sum[i] != 1) {
                  ^
  symbol:   variable i
  location: class Main
11 errors
Language: C++

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

int main() {
  int N, K, x=0; cin >> N >> K;
  vector<vector<int>> sunuke(N, vector<int>(0));
  for (int i=0; i<K; i++) {
    int d; cin >> d;
    for (int j=0; j<d; j++) {
      int A; cin >> A;
      sunuke.at(A).push_back(i);
    }
  }
  for (int i=0; i<N; i++) {
    if (sunuke.at(A).size()==0) x++;
  }
  cout << x << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:19: error: 'A' was not declared in this scope
   15 |     if (sunuke.at(A).size()==0) x++;
      |                   ^
Language: C++

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

int main() {
  int N, K;
  cin >> N >> K;
  vector<int> vec(N);
  for(int a = 0; a < N; a++){
    vec[a] = a + 1;
  }
  int b = N;
  
  for(int i = 0; i < K; i++){
    int x;
    cin >> x;
    for(int j = 0; j < x; j++){
      int y;
      cin >> y;
      for(int k = 0; k < b; k++){
        if(vec[k] == y){
          b -= 1;
          vec.erace(vec.begin() + k);
        }
      }
    }
  }
  cout << b << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:22:15: error: 'class std::vector<int>' has no member named 'erace'; did you mean 'erase'?
   22 |           vec.erace(vec.begin() + k);
      |               ^~~~~
      |               erase
Language: C

#include <bits/stdc++.h>
#include <string> 
using namespace std;
#define ll long long int
#define ld long double
#define pb push_back
#define mp make_pair
#define fi first
#define se second
#define mod 1000000007
#define mid 2019
#define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL)
#define fr(i,a,n) for(i=a;i<n;i++)
#define frn(i,a,n) for(i=a;i<=n;i++)
#define vll vector<ll>
#define pll pair<ll,ll>
#define vp vector<pll>
#define ub upper_bound
#define lb lower_bound
//#define map map<ll,ll>
#define mem(x,y) memset(x,y,sizeof(x))
#define all(v) v.begin(),v.end()
#define bs binary_search
#define qll queue<ll>
#define sll set<ll>
 
 
int main()
{
    fastio;
   
        ll count=0,abs=0,sum=0,index=-1,c=0;
       ll n,k,i,j,d;
       cin>>n>>k;
       ll h[n+1]={0};
       for(i=0;i<k;i++)
       {
           cin>>d;
           ll a[d];
           for(j=0;j<d;j++)
           cin>>a[j];
           
           for(j=0;j<d;j++)
           h[a[j]]++;
           
           
           
       }
       for(i=1;i<n+1;i++)
       {
           if(h[i]==0)
           count++;
       }
       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: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 人数の入力
		int ninzu = sc.nextInt();
		int okasi = sc.nextInt();
      	int[] sum = new int[ninzu]
      	for (i=0; i<okasi; i++){
        	int c = sc.nextInt();
          	for (j=0; j<c; j++){
              sum[sc.nextInt()] = 1;
            }
        }
      	int ans = 0;
      	for (i=0; i+1<sum.size(); i++) {
          if (sum[i] != 1) {
            ans += 1;
          }
        }
		// 出力
		System.out.println(ans;
	}
}

Compiler output:
Main.java:8: error: ';' expected
      	int[] sum = new int[ninzu]
      	                          ^
Main.java:22: error: ')' or ',' expected
		System.out.println(ans;
		                      ^
2 errors
Language: C++

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

int main() {
  int N, K, x=0; cin >> N >> K;
  vector<vector<int>> sunuke(N, vector<int>);
  for (int i=0; i<K; i++) {
    int d; cin >> d;
    for (int j=0; j<d; j++) {
      int A; cin >> A;
      sunuke.at(A).push_back(i);
    }
  }
  for (int i=0; i<N; i++) {
    if (sunuke.at(A).size()==0) x++;
  }
  cout << x << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:44: error: expected primary-expression before ')' token
    6 |   vector<vector<int>> sunuke(N, vector<int>);
      |                                            ^
a.cc:15:19: error: 'A' was not declared in this scope
   15 |     if (sunuke.at(A).size()==0) x++;
      |                   ^
Language: C++

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

int main() {
  int n,k;
  cin >>n>>k;
  vector<int> d(k);
  vector<vector<int>> a(k, vector<int>(n));
  vector<int> c(n);
  for(int i=0;i<k;i++){
    cin >> d.at(i);
    for(int j=0;j<d.at(i);j++){
      cin >> a.at(i).at(j);
      d.at(a.at(i).at(j))++;
    }
  }
  int ans=0;
  for(int i=0;i<n;i++){
    if(c(i)==0)ans++;
  }
  cout << ans<<endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:9: error: no match for call to '(std::vector<int>) (int&)'
   22 |     if(c(i)==0)ans++;
      |        ~^~~
Language: C

#include<stdio.h>
int main(){
  int n,k,d,cnt=0;
  scanf("%d %d",&n,&k);
  int sunu[n],dare;
  for(int i=0;i<p;i++){
    scanf("%d",&d);
    for(int j=0;j<d;j++){
      scanf("%d",&dare);
      sunu[dare]=1;
    }
  }
	for(int s=0;s<n;s++){
      if(sunu[s]==1)
        cnt++;
    }
  printf("%d",cnt);
}




Compiler output:
main.c: In function 'main':
main.c:6:17: error: 'p' undeclared (first use in this function)
    6 |   for(int i=0;i<p;i++){
      |                 ^
main.c:6:17: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

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

int main(){
	int n,k,ans = 0;
	vector<int> v;

	cin >> n >> k;
	
	for (int i = 0; i < k; i++) {
		int d;
		cin >> d;

		for (int j = 0; j < d; j++) {
			int a;
			cin >> a;
			v.push_back(a);
		}
	}

	for (int l = 1; l <= n; l++) {
		if (find(v.begin(), v.end(), l) == v.end()) {
			ans++;
		}
	}

	cout << ans;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:24:25: error: no matching function for call to 'find(std::vector<int>::iterator, std::vector<int>::iterator, int&)'
   24 |                 if (find(v.begin(), v.end(), l) == v.end()) {
      |                     ~~~~^~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/bits/locale_facets.h:48,
                 from /usr/include/c++/14/bits/basic_ios.h:37,
                 from /usr/include/c++/14/ios:46,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note: candidate: 'template<class _CharT2> typename __gnu_cxx::__enable_if<std::__is_char<_CharT2>::__value, std::istreambuf_iterator<_CharT> >::__type std::find(istreambuf_iterator<_CharT>, istreambuf_iterator<_CharT>, const _CharT2&)'
  435 |     find(istreambuf_iterator<_CharT> __first,
      |     ^~~~
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note:   template argument deduction/substitution failed:
a.cc:24:25: note:   '__gnu_cxx::__normal_iterator<int*, std::vector<int> >' is not derived from 'std::istreambuf_iterator<_CharT>'
   24 |                 if (find(v.begin(), v.end(), l) == v.end()) {
      |                     ~~~~^~~~~~~~~~~~~~~~~~~~~~~
Language: C++

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

int main() {
  int n,k;
  cin >> n >> k ;
 
  int input(){
    int d;
    cin >> d;
 vec<int> d1;   
    for(int i=0; i < 100;i++){
      d1.at(i) 
      
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:12: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 |   int input(){
      |            ^~
a.cc:8:12: note: remove parentheses to default-initialize a variable
    8 |   int input(){
      |            ^~
      |            --
a.cc:8:12: note: or replace parentheses with braces to value-initialize a variable
a.cc:8:14: error: a function-definition is not allowed here before '{' token
    8 |   int input(){
      |              ^
a.cc:15:2: error: expected '}' at end of input
   15 | }
      |  ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main(){

  int N,K;
  cin >> N >> K ;

  set<int> A;
  int a;
  int d[N+10];

  for(int i = 0; i < K; i++){
    cin >> d[i];
    for(int j = 0; j < d[i]; j++){
      cin >> a;
      A.insert(a);
    }
  }

  cout << N - A.size() << endl;


Compiler output:
a.cc: In function 'int main()':
a.cc:21:32: error: expected '}' at end of input
   21 |   cout << N - A.size() << endl;
      |                                ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main(){
  int ans=0;
  int N,K;
  cin>>N>>K;
  vector<int>d(K);
  for(int i=0;i<K;i++){
    cin>>d[i];
  }
  for(int j=0;j<N;j++){
    for(int i=0;i<K;i++){
      if(d[i]==j){
      ans++;
    }
  }
  cout<<N-ans<<endl;
}
    
  


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

import java.util.Scanner;
class Main{
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int k = sc.nextInt();
		int d;
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = 0;
		}
		for(int i = 0; i < k; i++) {
			d = sc.nextInt();
			for(int j = 0; j < d; j++) {
				int l = sc.nextInt();
				a[l-1] = 1;
			}
		}
		
		int count = 0;
		for(int i = 0; i < n; i++) {
			if(a[i] == 0) {
				count++;
			}
		}
		
		System.out.println(count);
	}


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

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

int main(){
  int ans=0;
  int N,K;
  cin>>N>>K;
  vector<int>d(K);
  for(int i=0;i<K;i++){
    cin>>d[i];
  }
  for(int j=0;j<N;j++){
    if(d[i]==j){
      ans++;
    }
  }
  cout<<N-ans<<endl;
}
    
  


Compiler output:
a.cc: In function 'int main()':
a.cc:13:10: error: 'i' was not declared in this scope
   13 |     if(d[i]==j){
      |          ^
Language: C++

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

int main(){
  int N, K;
  cin >> N, K;
  vector<vector<int>> A(K);
  vector<int> d(K);
  for(int i = 0; i < K; i++){
    cin >> d.at(i);
    A.push_back(vector<int>(d.at(i));
    for(int j = 0; j < d.at(i); j++){
      cin >> A.at(i).at(j);
    }
  }
  vector<bool> S(N, true);
  for(int i = 0; i < K; i++){
    for(int j = 0; j < d.at(i); i++){
      S.at(A.at(i).at(j)) = false;
    }
  }
  int count = 0;
  for(int i = 0; i < N; i++){
    if(S.at(i)){
      count ++;
    }
  }
  cout << count << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:37: error: expected ')' before ';' token
   11 |     A.push_back(vector<int>(d.at(i));
      |                ~                    ^
      |                                     )
Language: C++

//------------------------------------------
// C++ templete
//------------------------------------------
#include <bits/stdc++.h>
// #define int long long
using namespace std;

//typedef
//------------------------------------------
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<string> VS;
typedef vector<VS> VVS;

//REPEAT
//------------------------------------------
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define REP(i, n) FOR(i, 0, n)

//container util
//------------------------------------------
#define pb push_back
#define ALL(a) (a).begin(), (a).end()
#define PRINT(V)     \
  for (auto v : (V)) \
  cout << v << " "
#define PRINTL(V)    \
  for (auto v : (V)) \
  cout << v << endl
#define SORT(V) sort((V).begin(), (V).end())
#define RSORT(V) sort((V).rbegin(), (V).rend())

//最大公約数
//------------------------------------------
int GCD(int a, int b) { return b ? GCD(b, a % b) : a; }

//grobal variable
//------------------------------------------
int N, M;
VI Vec;

//main
//------------------------------------------
signed main()
{
  int d,n,k;
  cin >> n >> k;
  cin >> d;
  VVI a[k][n];
  for (int i = 0; i < k; i++){
    for (int j = 0; j < d; j++){
      pass
    }
  }
  cout << n-d;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:52:7: error: 'pass' was not declared in this scope
   52 |       pass
      |       ^~~~
Language: C++

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

int main() {
  int N, K;
  cin >> N >> K;
  vector(int) sunuke;
  for (int i = 0; i < N; i++) {
    sunuke.push_back(0);
  }
  for (int i = 0; i < K; i++) {
    int di;
    cin >> di;
    for (int j = 0; j < di; j++) {
      int index;
      cin >> index;
      sunuke[index] = 1;
    }
  }
  int count = 0;
  for (int sunu : sunuke) {
    if (sunu == 0) {
      count++;
    }
  }
  cout << count << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: missing template arguments before '(' token
    8 |   vector(int) sunuke;
      |         ^
a.cc:8:10: error: expected primary-expression before 'int'
    8 |   vector(int) sunuke;
      |          ^~~
a.cc:10:5: error: 'sunuke' was not declared in this scope
   10 |     sunuke.push_back(0);
      |     ^~~~~~
a.cc:18:7: error: 'sunuke' was not declared in this scope
   18 |       sunuke[index] = 1;
      |       ^~~~~~
a.cc:22:19: error: 'sunuke' was not declared in this scope; did you mean 'sunu'?
   22 |   for (int sunu : sunuke) {
      |                   ^~~~~~
      |                   sunu
Language: C++

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

int main(){
  int i=0;
  int N,K;
  cin>>N>>K;
  vector<int>d(K);
  for(int i=0;i<K;i++){
    cin>>d[i];
  }
  for(int i=0;i<N;i++){
    if(d[i]==i){
      ans++;
    }
  }
  cout<<N-ans<<endl;
}
    
  


Compiler output:
a.cc: In function 'int main()':
a.cc:14:7: error: 'ans' was not declared in this scope; did you mean 'abs'?
   14 |       ans++;
      |       ^~~
      |       abs
a.cc:17:11: error: 'ans' was not declared in this scope; did you mean 'abs'?
   17 |   cout<<N-ans<<endl;
      |           ^~~
      |           abs
Language: C++

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

int main(){
  int n,k;
  cin>>n>>k;
  vector<int> v(n);
  for(int i=0;i<n;i++){
    v[i]=0;
  }
  for(int i-0;i<k;i++){
    int d;
    cin>>d;
    for(int j=0;j<d;j++){
      int a;
      cin>>a;
      v[a]++;
    }
  }
  int sum=0;
  for(int i=0;i<n;i++){
    if(v[i]==0){
      sum++;
    }
  }
  cout<<sum<<endl;
}

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

int main(){
    int N;
    int K;

    int i;
    int di;
    int r;
    int dk;
    int result = 0;

    int flag[101] = {0};


    cin >> N >> K;
    for(i=0; i<K; i++){
        cin >> di;
        for(r=0; r<di; r++){
            cin >> dk;
            flag[dk] = 1;
        }
    }
    for(i=1; i<N; i++){
        if(flag[i] == 0){
            //cout << i << endl;
            result ++;
        }
    }
    cout << result << endl;


}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:5: error: 'cin' was not declared in this scope
   14 |     cin >> N >> K;
      |     ^~~
a.cc:28:5: error: 'cout' was not declared in this scope
   28 |     cout << result << endl;
      |     ^~~~
a.cc:28:23: error: 'endl' was not declared in this scope
   28 |     cout << result << endl;
      |                       ^~~~
Language: C

#include<stdio.h>

int main(){
  int n = 0, k = 0;
  scanf("%d%k", &n, &k);
  int d[k] = {0};
  int N[n] = {0};
  for(int i=0; i < k; i++){
    scanf("%d", &d[i]);
    for(int j=0; j < d[i]; j++){
      int tmp = 0;
      scanf("%d", &tmp);
      N[tmp-1]++;
    }
  }
  int count = 0;
  for(int c=0; c < n; c++){
    if(N[c] == 0)	count++;
  }
  printf("%d", count);
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:6:14: error: variable-sized object may not be initialized except with an empty initializer
    6 |   int d[k] = {0};
      |              ^
main.c:7:14: error: variable-sized object may not be initialized except with an empty initializer
    7 |   int N[n] = {0};
      |              ^
Language: C++

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

int main(){
  int i=0;
  int N,K,;
  cin>>N>>K;
  vector<int>d(K);
  for(int i=0;i<K;i++){
    cin>>d[i];
  }
  for(int i=0;i<N;i++){
    if(d[i]==i){
      ans++;
    }
  }
  cout<<N-ans<<endl;
}
    
  

Compiler output:
a.cc: In function 'int main()':
a.cc:6:11: error: expected unqualified-id before ';' token
    6 |   int N,K,;
      |           ^
a.cc:14:7: error: 'ans' was not declared in this scope; did you mean 'abs'?
   14 |       ans++;
      |       ^~~
      |       abs
a.cc:17:11: error: 'ans' was not declared in this scope; did you mean 'abs'?
   17 |   cout<<N-ans<<endl;
      |           ^~~
      |           abs
Language: C++

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

int main() {
  int n, k;
  cin >> n >> k;
  vector<int> d(k);
  vector<int> ansv(n,1);
  for(int i = 0; i < k; i++){
    cin >> d.at(i);
    vector<int> a(d.at(i));
    for(int j = 0; j < d.at(i); j++) cin >> a.at(j);
    
    for(int j = 0; j < d.at(i); j++){
      ansv.at(a.at(j)-1) = 0;
    }
  }
  int ans = 0;
  
  for( c : ansv)ans += c;
  cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:20:10: error: found ':' in nested-name-specifier, expected '::'
   20 |   for( c : ansv)ans += c;
      |          ^
      |          ::
a.cc:20:8: error: 'c' has not been declared
   20 |   for( c : ansv)ans += c;
      |        ^
a.cc:22:1: error: expected primary-expression before '}' token
   22 | }
      | ^
a.cc:21:23: error: expected ')' before '}' token
   21 |   cout << ans << endl;
      |                       ^
      |                       )
   22 | }
      | ~                      
a.cc:20:6: note: to match this '('
   20 |   for( c : ansv)ans += c;
      |      ^
a.cc:22:1: error: expected primary-expression before '}' token
   22 | }
      | ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
	
}#include<bits/stdc++.h>
#define int long long
#define vi vector<int>
#define vvi vector<vi>
#define vb vector<bool>
#define vvb vector<vb>
#define pb push_back
#define inf 1e18
#define mod 1000000007
#define ps(x,y) fixed<<setpricision(y)<<x
#define w(t) int t; cin>>t; while(t--)
#define setbits(x) __builtin_popcountll(x)
#define zrobits(x) __builtin_ctzll(x)
#define FIO ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define PI 3.14159265358979323846
using namespace std;
const int N = 300 * 1000 + 13;
void init() {
#ifndef ONLINE_JUDGE
	freopen("input.txt", "r", stdin);
	freopen("output.txt", "w", stdout);
#endif
}
int32_t main()
{
	FIO;
	init();
	int n, k; cin >> n >> k;
	map<int, int> mp;
	while (k--) {
		int d; cin >> d;
		for (int i = 0; i < d; i++) {
			int x; cin >> x;
		}
		mp[d]++;
	}
	int c = 0;
	for (int i = 1; i <= n; i++) {
		if (mp[i] == 0) c++;
	}
	cout << c << '\n';
}

Compiler output:
a.cc:5:2: error: stray '#' in program
    5 | }#include<bits/stdc++.h>
      |  ^
a.cc:5:3: error: 'include' does not name a type
    5 | }#include<bits/stdc++.h>
      |   ^~~~~~~
a.cc:28:9: error: redefinition of 'int32_t main()'
   28 | int32_t main()
      |         ^~~~
a.cc:3:5: note: 'int main()' previously defined here
    3 | int main(){
      |     ^~~~
Language: C++

#include<iostream>
using namespace std;

int main(){
  int n, k, d, a;
  cin >> n >> k;
  vector<int> arr(n + 1, 0);
  for(int i = 0; i < k; i++){
    cin >> d;
    for(int j = 0; j < d; j++){
      cin >> a;
      arr[a]++;
    }
  }
  int cnt = 0;
  for(int i = 1; i <= n; i++)
    if(!arr[i])
      cnt++;
  cout << cnt << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'vector' was not declared in this scope
    7 |   vector<int> arr(n + 1, 0);
      |   ^~~~~~
a.cc:2:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    1 | #include<iostream>
  +++ |+#include <vector>
    2 | using namespace std;
a.cc:7:10: error: expected primary-expression before 'int'
    7 |   vector<int> arr(n + 1, 0);
      |          ^~~
a.cc:12:7: error: 'arr' was not declared in this scope
   12 |       arr[a]++;
      |       ^~~
a.cc:17:9: error: 'arr' was not declared in this scope
   17 |     if(!arr[i])
      |         ^~~
Language: C++

#include<iostream>
#include<vector>
int main(){
	int n,k;
  	cin>>n>>k;
  	vector<int> v(n,0);
  	int a;
  	for(int i=0;i<n;i++){
    	cin>>a;
      for(int j=0;j<a;j++){
      	int x;
        cin>>x;
        v[x]++;
      }
    }
  int count=0;
  for(int i=0;i<n;i++){
  	if(v[i]==0)
      	count++;
  }
  cout<<count<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |         cin>>n>>k;
      |         ^~~
      |         std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:6:9: error: 'vector' was not declared in this scope
    6 |         vector<int> v(n,0);
      |         ^~~~~~
a.cc:6:9: note: suggested alternatives:
In file included from /usr/include/c++/14/vector:66,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_vector.h:428:11: note:   'std::vector'
  428 |     class vector : protected _Vector_base<_Tp, _Alloc>
      |           ^~~~~~
/usr/include/c++/14/vector:93:13: note:   'std::pmr::vector'
   93 |       using vector = std::vector<_Tp, polymorphic_allocator<_Tp>>;
      |             ^~~~~~
a.cc:6:16: error: expected primary-expression before 'int'
    6 |         vector<int> v(n,0);
      |                ^~~
a.cc:13:9: error: 'v' was not declared in this scope
   13 |         v[x]++;
      |         ^
a.cc:18:12: error: 'v' was not declared in this scope
   18 |         if(v[i]==0)
      |            ^
a.cc:21:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   21 |   cout<<count<<endl;
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:21:16: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   21 |   cout<<count<<endl;
      |                ^~~~
      |                std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <cstdio>
#include <stdlib.h>
#include <algorithm>
using namespace std;
int main() {
	int N, K;
    int A[110] = {0};
	scanf("%d %d", &N, &K);
    for(int i=0; i < K; i++) {
        int d;
        scanf("%d", &d);
        for (int j=0; j < d; j++) {
            int a;
            scanf("%d", &a);
            A[a]++;
        }
    }
    int count = 0;
    for (int i=0; i < N; i++) {
        if (A[i] == 0) {
            count++;
        }
    }
    printf("%d\n", count-1);
}#include <cstdio>
#include <stdlib.h>
#include <algorithm>
using namespace std;
int main() {
	int N, K;
    int A[110] = {0};
	scanf("%d %d", &N, &K);
    for(int i=0; i < K; i++) {
        int d;
        scanf("%d", &d);
        for (int j=0; j < d; j++) {
            int a;
            scanf("%d", &a);
            A[a]++;
        }
    }
    int count = 0;
    for (int i=0; i < N; i++) {
        if (A[i] == 0) {
            count++;
        }
    }
    printf("%d\n", count-1);
}

Compiler output:
a.cc:25:2: error: stray '#' in program
   25 | }#include <cstdio>
      |  ^
a.cc:25:3: error: 'include' does not name a type
   25 | }#include <cstdio>
      |   ^~~~~~~
a.cc:29:5: error: redefinition of 'int main()'
   29 | int main() {
      |     ^~~~
a.cc:5:5: note: 'int main()' previously defined here
    5 | int main() {
      |     ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main() {
	int n, k, d,i;
	cin >> n >> k >> d;
	ans = n - d;
	cout >> ans >> endl;
	return 0;
}

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

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

int main() {
  int n,m;
  cin >> n >> m;
  
  int arr[n] = {};
  vector<int> v(arr, arr+sizeof(arr));
  
  int a,b;
  for(int i = 0; i < m; ++i) {
    cin >> a;
    for (int j = 0; j < a; ++j) {
      cin >> b;
      arr[b]++;
    }
  }
  
  cout << count(v.begin(), v.end(), 0); << "\n";
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:11: error: 'count' was not declared in this scope
   21 |   cout << count(v.begin(), v.end(), 0); << "\n";
      |           ^~~~~
a.cc:21:41: error: expected primary-expression before '<<' token
   21 |   cout << count(v.begin(), v.end(), 0); << "\n";
      |                                         ^~
Language: Java

import java.util.Scanner;

public class Main {
	public static void main(String args[]) {
		Scanner scan = new Scanner(System.in);
		int ninz = scan.nextInt(), syuru = scan.nextInt();
		int hito[] = new int[ninz];
		
		for(int i = 0; i < syuru; i++) {
			int ha = scan.nextInt();
			for(int j = 0; i < ha; i++) {
				hito[scan.nextInt() - 1]++;
				
			}
			
			
		}
		
		syuru = 0;
		
		for(int i = 0; i < ninz; j++) {
			if(hito[i] == 0) {
				syuru++;
			}
			
		}
		
		System.out.println(syuru);
		
		
	}
		
		
		
}


Compiler output:
Main.java:21: error: cannot find symbol
		for(int i = 0; i < ninz; j++) {
		                         ^
  symbol:   variable j
  location: class Main
1 error
Language: C++

#include<stdio.h>
int n,k;
std::set<int> x;
int main()
{
  scanf("%d%d",&n,&k);
  while(k--)
  {
    int d;
    scanf("%d",&d);
    while(d--)
    {
      int a;
      scanf("%d",&a);
    }
  }
  printf("%d\n",n-x.size());
  return 0;
}

Compiler output:
a.cc:3:6: error: 'set' in namespace 'std' does not name a template type
    3 | std::set<int> x;
      |      ^~~
a.cc:2:1: note: 'std::set' is defined in header '<set>'; this is probably fixable by adding '#include <set>'
    1 | #include<stdio.h>
  +++ |+#include <set>
    2 | int n,k;
a.cc: In function 'int main()':
a.cc:17:19: error: 'x' was not declared in this scope
   17 |   printf("%d\n",n-x.size());
      |                   ^
Language: C

#include<stdio.h>

int main(){
  int n, k;
  scanf("%d%k", &n, &k);
  int d[k] = {0};
  int N[n] = {0};
  for(int i=0; i < k; i++){
    scanf("%d", &d[i]);
    for(int j=0; j < d[i]; j++){
      int tmp = 0;
      scanf("%d", &tmp);
      N[tmp-1]++;
    }
  }
  int count = 0;
  for(int c=0; c < n; c++){
    if(N(c) == 0)	count++;
  }
  printf("%d", count);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:14: error: variable-sized object may not be initialized except with an empty initializer
    6 |   int d[k] = {0};
      |              ^
main.c:7:14: error: variable-sized object may not be initialized except with an empty initializer
    7 |   int N[n] = {0};
      |              ^
main.c:18:8: error: called object 'N' is not a function or function pointer
   18 |     if(N(c) == 0)       count++;
      |        ^
main.c:7:7: note: declared here
    7 |   int N[n] = {0};
      |       ^
Language: C++

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

int main() {
  int a,b;
  cin>>a>>b;
  int d[b];
  int sum=0;
  stack<int> N;
  for(int i=0;i<b;i++) {
    cin>>d[i];
    for(int j=0;j<d[i];j++) {
      int c;
      cin>>c;
      N.push(c);
    }
    
  }
  int ans=0;
  sort(N.begin(),N.end());
  for(int i=0;i<a;i++) {
    if(N.at(i)!=N.at(i+1)&&N.at(i)!=N.at(i+1)-1){
      ans++;
    }
  }
  cout<<ans<<endl;
  return 0;
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:20:10: error: 'class std::stack<int>' has no member named 'begin'
   20 |   sort(N.begin(),N.end());
      |          ^~~~~
a.cc:20:20: error: 'class std::stack<int>' has no member named 'end'
   20 |   sort(N.begin(),N.end());
      |                    ^~~
a.cc:22:10: error: 'class std::stack<int>' has no member named 'at'
   22 |     if(N.at(i)!=N.at(i+1)&&N.at(i)!=N.at(i+1)-1){
      |          ^~
a.cc:22:19: error: 'class std::stack<int>' has no member named 'at'
   22 |     if(N.at(i)!=N.at(i+1)&&N.at(i)!=N.at(i+1)-1){
      |                   ^~
a.cc:22:30: error: 'class std::stack<int>' has no member named 'at'
   22 |     if(N.at(i)!=N.at(i+1)&&N.at(i)!=N.at(i+1)-1){
      |                              ^~
a.cc:22:39: error: 'class std::stack<int>' has no member named 'at'
   22 |     if(N.at(i)!=N.at(i+1)&&N.at(i)!=N.at(i+1)-1){
      |                                       ^~
Language: Java

import java.util.*;
 
public class Main{
 public static void main(String arg[])
 {
  Scanner sc=new Scanner(System.in);
   int n=sc.nextInt();
   int k=sc.nextint();
   int a[]=new int[n+1];
   
   for(int i=0;i<n;i++)
   {
      int t=sc.nextInt();
      for(int i=0;i<t;i++)a[sc.nextInt]++;
   }
   int m=0;
   for(int i=1;i<=k && i<=n;i++)if(a[i]==0)m++;
   System.out.println(m);
   
   
 }
  
}

Compiler output:
Main.java:8: error: cannot find symbol
   int k=sc.nextint();
           ^
  symbol:   method nextint()
  location: variable sc of type Scanner
Main.java:14: error: variable i is already defined in method main(String[])
      for(int i=0;i<t;i++)a[sc.nextInt]++;
              ^
Main.java:14: error: cannot find symbol
      for(int i=0;i<t;i++)a[sc.nextInt]++;
                              ^
  symbol:   variable nextInt
  location: variable sc of type Scanner
3 errors
Language: Java

import java.util.*;

public class Main{
      public static void main(String[] args) {
            Scanner sc = new Scanner(System.in);
            int N = sc.nextInt();
            int K = sc.nextInt();
            int d = sc.nextInt();
            if(N-d > 0){
            System.out.println(N-d);
          } else {
            System.out.println(0);
          }
}

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

#include<iostream>
#include<cstdio>
#include<cstring>
#include<cmath>
#include<string>
#include<vector>
#include<algorithm>
using namespace std;
const int MR=110;
typedef long long LL;

int main() {
	int n,k;
	int d,a;
	bool v[MR];
	memset(v,0,szieof(v));
	cin>>n>>k;
	for(int i=0;i<k;i++){
		cin>>d;
		for(int j=0;j<d;j++){
			cin>>a;
			v[a]=true;
		}
	}
	int cnt=0;
	for(int i=1;i<=n;i++){
		if(!v[i]) cnt++;
	}
	printf("%d\n",cnt);
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:20: error: 'szieof' was not declared in this scope
   16 |         memset(v,0,szieof(v));
      |                    ^~~~~~
Language: C++

#include <iostream>
#include <cmath>
#include <algorithm>
#include <string> //文字列
#include <iomanip> //doubleの桁数指定 setprecision()
#include <list> //前後に数値を入れれる配列
#include <map> //map
#include <vector> //vecror

#define REP(i,m,n) for(ll i = (ll) (m);i < (ll) (n);i++) //forの短縮
#define rep(i,n) REP(i,0,n) //REPが0の時
#define ll long long int

using namespace std;

double PI = acos(-1); //円周率
ll mod = 1e9 + 7;


//提出コード

ll n, k,cnt,d[110];
ll a[110];
bool J[110];


int main() {
	cin >> n >> k;
	rep(i, k) {
		cin >> d[i];
		rep(j, d[i]) {
			cin >> a[j];
			J[a[j]]++;
		}
	}
	REP(i, 1, n + 1) {
		if(!(J[i])) cnt++;
	}
	cout << cnt << endl;

	return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:33:31: error: use of an operand of type 'bool' in 'operator++' is forbidden in C++17
   33 |                         J[a[j]]++;
      |                         ~~~~~~^
Language: Java

import java.util.*;
 
public class Main{
 public static void main(String arg[])
 {
  Scannet sc=new Scanner(System.in);
   int n=sc.nextInt();
   int k=sc.nextint();
   int a[]=new int[n+1];
   
   for(int i=0;i<n;i++)
   {
      int t=sc.nextInt();
      for(int i=0;i<t;i++)a[sc.nextInt]++;
   }
   int m=0;
   for(int i=1;i<=n;i++)if(a[i]==0)m++;
   System.out.println(m);
   
   
 }
  
}

Compiler output:
Main.java:6: error: cannot find symbol
  Scannet sc=new Scanner(System.in);
  ^
  symbol:   class Scannet
  location: class Main
Main.java:14: error: variable i is already defined in method main(String[])
      for(int i=0;i<t;i++)a[sc.nextInt]++;
              ^
2 errors
Language: C

#include<stdio.h>

int main(){
  int n,k,ans,flag;
  scanf("%d%d",&n,&k);
  int d[k+1],a[k+1][n+1];
  
  for(int i=1;i<=k;i++){
    for(j=1;j<=n;j++){
      a[i][j]=0;
    }
  }
  
  for(int i=1;i<=k;i++){
    scanf("%d",d[i]);
    for(int j=1;j<=d[i];j++){
      scanf("%d",a[i][j]);
    }
  }
  
  for(int i=1;i<=n;i++){
    flag=0;
    for(int j=1;j<=k;j++){
      if(a[j][i]!=0){
        flag=1;
        break;
      }
    }
    if(flag==0){ans+=1;}
  }
  printf("%d",ans);
  return 0;
}

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

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

int main()
{
	
	int n, k;
	int d[100], a[100][100];
	scanf("%d %d", &n, &k);
	bool c[100];

	for (int i = 0; i != k; i++) 
	{
		scanf("%d", &d[i]);
		for (int j = 0; j != d[i]; j++) 
		{
			scanf("%d", &a[i][j]);
			c[a[i][j]] = true;
		}
	}
	
	int b = 0;
	for (int i = 0; i != n; i++) 
	{
		if (!c[i]) 
		{
			b++;
		}
	}
	printf("%d", b);

	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:9: error: unknown type name 'bool'
   10 |         bool c[100];
      |         ^~~~
main.c:3:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
    2 | #include <string.h>
  +++ |+#include <stdbool.h>
    3 | 
main.c:18:38: error: 'true' undeclared (first use in this function)
   18 |                         c[a[i][j]] = true;
      |                                      ^~~~
main.c:18:38: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:18:38: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int main(){
  int n, k;
  scanf("%d", &n);
  int a[n+1], i, j, t;
  for(i=1;i<n+1;i++)a[i]=0;
  while(k--){
    scanf("%d",&i);
    for(j=0; j<i; j++){
      scanf("%d", &t);
      a[t]+=1;
    }
  }
  for(i=1;i<n+1;i++){
    if(a[i]==0){
      printf("%d\n",i);
      break;
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:20:1: error: expected declaration or statement at end of input
   20 | }
      | ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){int N,K,d,x;cin>>N>>K;vector<int>a(N,1);x=N;
   for(int i=0;i<K;i++){cin>>d;for(int j=0;j<d;j++){cin>>b;if(a.at(b-1)){a.at(b-1)=0;x--;}}}
           cout<<x<<endl;}


Compiler output:
a.cc: In function 'int main()':
a.cc:4:58: error: 'b' was not declared in this scope
    4 |    for(int i=0;i<K;i++){cin>>d;for(int j=0;j<d;j++){cin>>b;if(a.at(b-1)){a.at(b-1)=0;x--;}}}
      |                                                          ^
Language: Java

import java.util.*;

public class Main{
 public static void main(String arg[])
 {
  Scannet sc=new Scanner(System.in);
   int n=sc.nextInt();
   int k=sc.nextint();
   int a[]=new int[n+1];
   
   for(int i=0;i<n;i++)
   {
      int t=sc.nextInt();
      for(int i=0;i<t;i++)a[sc.nextInt]++;
   }
   int m=0;
   for(int i=1;i<=n;i++)if(a[i]==0)m++;
   System.out.println(m);
   
   
 }
  
}

Compiler output:
Main.java:6: error: cannot find symbol
  Scannet sc=new Scanner(System.in);
  ^
  symbol:   class Scannet
  location: class Main
Main.java:14: error: variable i is already defined in method main(String[])
      for(int i=0;i<t;i++)a[sc.nextInt]++;
              ^
2 errors
Language: C++

#include <iostream>
using namespace std;

int main(){
  int x;
  int n, k;
  cin >> n >> k;
  int d[k];
  int ans[n]={0};
  for(int i=0;i<k;i++){
    cin >> d[i];
    for(j=0;j<d[i];j++){
      cin >> x;
      ans[x-1]+=1;
    }
  }
  int count=0 ;
  for(int i=0;i<n;i++){
    if(ans[i]==0) count+=1;
  }
}

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

int main(){
    int n;
    int k;
    
    int x;
    int A;

    cin >> n >> k;

    int a[n + 1];

    for(int i = 1; i <= n; i++){
        a[i] = 1;
    }

   
    for(int i = 0; i < k; i++){
        cin >> x;
        for(int j = 0; j < x; j++){
            cin >> A;
            a[A] = 0;
        }

    }

    int sum = 0;

    for(int i = 1; i <= n; i++){
        sum = sum + a[i];
    }

    printf("%d\n", sum);

    return 0;
    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:5: error: 'cin' was not declared in this scope
    8 |     cin >> n >> k;
      |     ^~~
a.cc:32:5: error: 'printf' was not declared in this scope
   32 |     printf("%d\n", sum);
      |     ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main(){
Language: C++

#include <iostream>
using namespace std;

int main(int argc, const char * argv[]) {
    int N, K;
    cin >> N;
    cin >> K;
    bool *sunuke = new bool[N];
    memset(sunuke, false, sizeof(bool) * N);
    
    for (int i = 0; i < K; i++) {
        int d;
        cin >> d;
        for (int j = 0; j < d; j++) {
            int A;
            cin >> A;
            sunuke[A - 1] = true;
        }
    }
    
    int ans = 0;
    for (int i = 0; i < N; i++) {
        if (!sunuke[i]) {
            ans++;
        }
    }
    
    cout << ans << endl;

    return 0;
}


Compiler output:
a.cc: In function 'int main(int, const char**)':
a.cc:9:5: error: 'memset' was not declared in this scope
    9 |     memset(sunuke, false, sizeof(bool) * N);
      |     ^~~~~~
a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <iostream>
  +++ |+#include <cstring>
    2 | using namespace std;
Language: C++

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

int main() {
  int N,K;
  cin >> N >> K;
  vector<int> D(K);
  for(int i=0;i<K;i++){
  cin >> D.at(i);
  vector<int> A(vector.size(i));
if (S =="ABC"){
  cout << "ARC" << endl;
}
else{
  cout << "ABC" << endl;
}
  // ここにプログラムを追記
  // (ここで"試合結果の表"の2次元配列を宣言)
}
}}}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:17: error: missing template argument list after 'std::vector'; template placeholder not permitted in parameter
   10 |   vector<int> A(vector.size(i));
      |                 ^~~~~~
      |                       <>
In file included from /usr/include/c++/14/vector:66,
                 from /usr/include/c++/14/functional:64,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:53,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_vector.h:428:11: note: 'template<class _Tp, class _Alloc> class std::vector' declared here
  428 |     class vector : protected _Vector_base<_Tp, _Alloc>
      |           ^~~~~~
a.cc:10:23: error: expected ',' or '...' before '.' token
   10 |   vector<int> A(vector.size(i));
      |                       ^
a.cc:11:5: error: 'S' was not declared in this scope
   11 | if (S =="ABC"){
      |     ^
a.cc: At global scope:
a.cc:20:2: error: expected declaration before '}' token
   20 | }}}
      |  ^
a.cc:20:3: error: expected declaration before '}' token
   20 | }}}
      |   ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int n,k;
  cin>>n>>k;
  vector<int> b(n);
  for(int i=0;i<n;i++){
    b(i)=0;
  }
  for(int i=0;i<k;i++){
    int d;
    cin>>d;
    for(int j=0;j<d;j++){
      int a;
      cin>>a;
      b.at(a-1)++;
    }
  }
  int ans=0;
  for(int i=0;i<n;i++){
    if(b.at(i)==0) ans++;
  }
  cout<<ans<<endl;
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:6: error: no match for call to '(std::vector<int>) (int&)'
    8 |     b(i)=0;
      |     ~^~~
Language: Java

import java.util.*;
public class Main2
{
public static void main(String args[])
{
Scanner sc=new Scanner(System.in);
int n=sc.nextInt();
int k=sc.nextInt();
Set<Integer> s=new HashSet<>();
while(k-->0)
{
int d=sc.nextInt();
while(d-->0)
{
int a=sc.nextInt();
s.add(a);
}
}

System.out.println(n-s.size());
}
}


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

#include<bits/stdc++h>
using namespace std;
int main(){int N,K,d,x;cin>>N>>K;vector<int>a(N,1);x=N;
   for(int i=0;i<K;i++){cin>>d;for(int j=0;j<d;j++){cin>>b;if(a.at(b-1)){a.at(b-1)=0;x--;}}}
           cout<<x<<endl;}

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

#incldue <iostream>
#include <vector>
using namespace std;
int main(){
  int n,k,d,temp,ans=0;
  cin>>n>>k;
  vector<bool>z(n,false);
  for(int i=0;i<k;i++){
    cin>>d;
    for(int j=0;j<d;i++){
      cin>>temp;
      z[temp-1]=true;
    }
  }
  for(auto i:z){
    if(!i){
      ans++;
    }
  }
  cout<<ans<<endl;
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #incldue; did you mean #include?
    1 | #incldue <iostream>
      |  ^~~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin>>n>>k;
      |   ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    2 | #include <vector>
  +++ |+#include <iostream>
    3 | using namespace std;
a.cc:20:3: error: 'cout' was not declared in this scope
   20 |   cout<<ans<<endl;
      |   ^~~~
a.cc:20:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:20:14: error: 'endl' was not declared in this scope
   20 |   cout<<ans<<endl;
      |              ^~~~
a.cc:3:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    2 | #include <vector>
  +++ |+#include <ostream>
    3 | using namespace std;
Language: C

#include<iostream>
#include<cstdlib>
template<typename T>
void fin(T const& t){ std::cout << t << std::endl; exit(0); }

int const MAXN = 100;
bool k[MAXN];

int main() {
  int N, K; std::cin >> N >> K;
  std::fill_n(k, N, true);
  for(int i = 0; i < K; ++i) {
    int d; std::cin >> d;
    for(int j = 0; j < d; ++j) {
      int A; std::cin >> A; --A;
      k[A] = false;
    }
  }
  int ans = 0;
  for(int i = 0; i < N; ++i) if(k[i]) ++ans;
  fin(ans);
  return 0;
}


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