stablegradients/pie-gem5-pairs huggingface dataset:
// Slower C++ solution:
#include <iostream>

#include<vector>

#include<algorithm>

#include<map>

#include<set>

#include<string>

#include<math.h>



using namespace std;



struct node{

 int x;

 int time;

 bool operator <(node &B)

 {

     if(time<B.time) return true;

     if(time==B.time) return x<B.x;

     return false;

 }

};

int main()

{

    int n;cin>>n;

    set<int>nums;

    for(int i=0;i<n;i++)

{

    int a;

    cin>>a;

    if(nums.count(a))

    {

        nums.erase(a);

    }else

    nums.insert(a);

}

cout<<nums.size()<<endl;





return 0;

}




// Faster C++ solution for the same problem (measured speedup: 1.6969914669126425x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<cstdio>

#include<cstring>

#include<iostream>

#include<map>

#include<cmath>

//#include<windows.h>

#include<algorithm>

#include<set>

const double eps = 1e-1;

using namespace std;

typedef long long ll;

map<int,int>play;

int main(){



    int n;

    scanf("%d",&n);

    int num=0;

    while(n--){

        int t;

        scanf("%d",&t);

        if(play[t]==1)play[t]--,num--;

        else play[t]++,num++;

    }

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

    return 0;

}

//Hello World Here I Come

//          0                 10

//        0 1 1                8

//      0 1 1 2 3              6

//    0 1 1 2 3 5 8            4

//  0 1 1 2 3 5 8 13 21        2

//0 1 1 2 3 5 8 13 21 34 55    0


// Faster C++ solution for the same problem (measured speedup: 1.664720179749575x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <set>

using namespace std;



int main()

{

    int n,i,t;

    scanf("%d",&n);

    set<int> a;

    for(i=0;i<n;i++){

        scanf("%d",&t);

        if(a.end()==a.find(t))

            a.insert(t);

        else

            a.erase(t);

    }

    printf("%d",a.size());

}


// Faster C++ solution for the same problem (measured speedup: 1.6768137590644496x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<iostream>

#include<map>

#include<string>

#include<algorithm>

using namespace std;



int main() {

	int nums;

	map<string,bool> a;

	scanf("%d", &nums);

	map<string, bool> ::iterator it;

	for (int i = 0; i < nums; i++) {

		string temp;

		cin >> temp;

		it = a.find(temp);

		if (it != a.end()) a.erase(it);

		else a[temp] = 1;

	}

	cout << a.size();

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 1.7030103334167095x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

    int n;

    scanf("%d",&n);

    set<int> a;

    int x;

    for(int i = 0; i < n; i++)

    {

        cin >> x;

        if(a.count(x) == 1)

            a.erase(x);

        else

            a.insert(x);



    }

    printf("%d",a.size());

    return 0;



}

// Faster C++ solution for the same problem (measured speedup: 1.6866307655124488x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <map>

using namespace std;



int main()

{

    int n,temp,con = 0;

    scanf("%d",&n);

    map<int,int> spare;

    for(int i = 1; i != n+1; ++i)

    {

        scanf("%d",&temp);

        if(spare[temp] == 0){

            spare[temp] = 1;

            con++;

        }

        else{

            spare[temp] = 0;

            con--;

        }

    }

    printf("%d",con);

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.67699293921206x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <iostream>

using namespace std;

#include <algorithm>



int main(){

    std::ios::sync_with_stdio(false);

    int n,i,j,number,total=0,count;

    cin>>n;

    long long a[n],b[n][2]={};

    for(i=0;i<n;i++){

        cin>>a[i];

    }

    sort(a,a+n);

    i=0;

    while(i<n){

        number=a[i];

        count=0;

        while(i<n && a[i]==number){

            count++;

            i++;

        }

        total+=count%2;

    }



    cout<<total;





    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.7026991561892424x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<stdio.h>

#include<string.h>

#include<stdlib.h>

#include<iostream>

#include<algorithm>

#include<string>

#include<map>

#define maxn 1005

using namespace std;

typedef long long  LL;

map<string,int>mp;

int main()

{

    int n;

    scanf("%d",&n);

    while(n--)

    {

        string s;

        cin>>s;

        mp[s]++;

    }

        map<string,int>::iterator it;

        int sum=0;

        for(it=mp.begin();it!=mp.end();++it)

        {

            int t=it->second;

            if(t%2==1)

                sum++;

        }

        cout<<sum<<endl;



}


// Faster C++ solution for the same problem (measured speedup: 1.705595119058961x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;



int a[100001];



int main()

{

	int i,j,k,m,n;

	cin>>n;



	for(i=0; i<n; i++)

		cin>>a[i];



	sort(a,a+n);

	int ans=0;

	for(i=0;i<n;i++)

	{

		if(a[i]==a[i+1])

		{

			i++;

			continue;

		}

		else

			ans++;

	}

	cout<<ans;

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 1.6770930176707741x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;



int main(){

	int n,cnt=0,x;

	set<int> s;

	cin>>n;

	for(int i=0;i<n;i++){

		cin>>x;

		if(s.find(x)!=s.end()){

			s.erase(x);

//			cout<<"00"<<endl;

			cnt++;

		}else{

			s.insert(x);

		}

	}

	cout<<n-2*cnt<<endl;

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 1.6979938217118502x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <iostream>

#include <string.h>

#include <cstdio>

#include <algorithm>

#include <string>

#include <math.h>

#include <map>

using namespace std;

#define ll long long

int n,m;

map<int,int> mp;

int main()

{

    scanf("%d",&n);

    int cnt = 0 ,x;

    for(int i=1;i<=n;i++)

    {

        scanf("%d",&x);

        if(mp[x] == 0)

        {

            mp[x] = 1;

            cnt++;

        }

        else{

            if(mp[x] == 1)

            {

                mp[x] = 0;

                cnt--;

            }

        }

    }

    cout<<cnt<<endl;

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.6844679698509357x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<iostream>

#include<algorithm>

#include<cmath>

#include<cstring>

using namespace std;

int map[100005];

int main()

{

	int n,sum;

	cin>>n;

	for(int i=0; i<n; i++)

	{

		cin>>map[i];

	}

	sort(map,map+n);

	int a,ssum=1;

	a=map[0];

	for(int i=1; i<n; i++)

	{

		if(a==map[i])

		{

			ssum++;

			if(i==n-1)

				sum+=(ssum%2);

		}

		else

		{

			a=map[i];

			sum+=(ssum%2);

			ssum=1;

			if(i==n-1)

				sum++;

		}



	}

	cout<<sum<<endl;

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 1.6799678909680837x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;

set<int>s;

int a[100010];

int main()

{

	int n;

	scanf("%d",&n);

	int x;

	while(n--)

	{

		scanf("%d",&x);

		if(s.find(x)!=s.end())

		{

			s.erase(x);

		}

		else

		{

			s.insert(x);

		}	

	}

	

	printf("%d",s.size());

	return 0;

 } 

// Faster C++ solution for the same problem (measured speedup: 1.6765587620393922x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include <iostream>

#include <stdio.h>

#include <map>

using namespace std;



int main()

{

    int n,num;

    map<int,int> m;

    map<int,int>::iterator iter;

    scanf("%d",&n);

    for(int i = 0;i < n;i++)

    {

        scanf("%d",&num);

        iter = m.find(num);

        if(iter!=m.end())

            m.erase(num);

        else

            m[num]=1;

    }

    printf("%d\n",m.size());

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.6770288194601977x):
#include<stdio.h>

#include<stdlib.h>



int cmp(const void *a,const void *b){

	return *(int *)a-*(int *)b;

}



int main(){

	int N,a[100005]={0};

	scanf("%d",&N);

	for(int i=0;i<N;i++){

		scanf("%d",&a[i]);

	}

	qsort(a,N,sizeof(a[0]),cmp);

	int cnt=1,res=0;

	for(int i=1;i<N;i++){

		if(a[i]!=a[i-1]){

			if(cnt%2!=0){

				res++;

			}

			cnt=1;

		}

		else{

			cnt++;

		}

	}

	if(cnt%2!=0){

		res++;

	}

	printf("%d",res);

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

	string A[100001];

int main()

{

	long long N,total=0;

	cin>>N;

	map<string,bool>number;

	for(int i=0;i<N;i++)

	{

		cin>>A[i];

		number[A[i]]=false;

	}

	for(int i=0;i<N;i++)

	{

		if(number[A[i]]==false)

		{

			number[A[i]]=true;

			total+=1;

		}

		else

		{

			number[A[i]]=false;

			total-=1;

		}

	}

	cout<<total<<endl;

}

// Faster C++ solution for the same problem (measured speedup: 4.432398509121055x):
#include<bits/stdc++.h>

using namespace std;

typedef long long ll;

ll arr[(int)1e6+5];

int main(){

	int n;

	scanf("%d",&n);

	for(int i=0;i<n;i++){

		scanf("%lld",&arr[i]);

	}

	sort(arr,arr+n);

	ll ans=1;

	bool exist=true;

	for(int i=1;i<n;i++){

		if(arr[i]!=arr[i-1]){

			exist=true;

			ans++;

		}

		

		else{

			if(exist==1){

				ans--;

			}

			

			else{

				ans++;

			}

			exist^=1;

			

		}

	}

	

	printf("%lld\n",ans);

	

	

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

	string A[100001];

int main()

{

	long long N,total=0;

	cin>>N;

	map<string,bool>number;

	for(int i=0;i<N;i++)

	{

		cin>>A[i];

		number[A[i]]=false;

	}

	for(int i=0;i<N;i++)

	{

		if(number[A[i]]==false)

		{

			number[A[i]]=true;

			total+=1;

		}

		else

		{

			number[A[i]]=false;

			total-=1;

		}

	}

	cout<<total<<endl;

}

// Faster C++ solution for the same problem (measured speedup: 4.3831026084092x):
#include <bits/stdc++.h>

using namespace std;

map <int, int> x;

int main() {

	int n, a, ans=0;

	scanf("%d", &n);

	while(n--) {

		scanf("%d", &a);

		x[a]++;

	}

	for(map<int,int>::iterator it = x.begin(); it!= x.end(); it++) {

		if(it->second % 2 == 1) ans++;

	}

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

	return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

	string A[100001];

int main()

{

	long long N,total=0;

	cin>>N;

	map<string,bool>number;

	for(int i=0;i<N;i++)

	{

		cin>>A[i];

		number[A[i]]=false;

	}

	for(int i=0;i<N;i++)

	{

		if(number[A[i]]==false)

		{

			number[A[i]]=true;

			total+=1;

		}

		else

		{

			number[A[i]]=false;

			total-=1;

		}

	}

	cout<<total<<endl;

}

// Faster C++ solution for the same problem (measured speedup: 4.326249001746576x):
#include<bits/stdc++.h>

using namespace std;



typedef long long ll;



ll a[100010];



int main() {

	

	ios_base::sync_with_stdio(false);

	cin.tie(NULL);



	ll n;

	cin>>n;



	for(ll i=0;i<n;i++) cin>>a[i];



	sort(a, a+n);



	ll ans = 0;



	ll cnt = 1;

	for(ll i=1;i<n;i++) {

		if(a[i] == a[i-1]) cnt++;

		else {

			ans += cnt % 2;

			cnt = 1;

		}

	}

	ans += cnt % 2;



	cout<<ans<<endl;

	

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int n,x,ans;

map<int,int> mp;

int main(){

	scanf("%d",&n);

	for (int i=1;i<=n;i++){

		scanf("%d",&x);

		if (mp[x]) ans--;

		else ans++;

		mp[x]^=1;

	}

	printf("%d",ans);

}

// Faster C++ solution for the same problem (measured speedup: 1.6909023946847292x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}
// Slower C++ solution:
#include <bits/stdc++.h>

#define N 100020

#define ll long long

using namespace std;

inline int read(){

	int x=0,f=1;char ch=getchar();

	while(ch>'9'||ch<'0')ch=='-'&&(f=0)||(ch=getchar());

	while(ch<='9'&&ch>='0')x=(x<<3)+(x<<1)+ch-'0',ch=getchar();

	return f?x:-x;

}

std::map<int, bool> mp;

int main(int argc, char const *argv[]) {

	int n = read(), ans = 0;

	for (int i = 1; i <= n; i++) {

		int x = read();

		if (mp[x]) ans --, mp[x] = 0;

		else       ans ++, mp[x] = 1;

	}

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

	return 0;

}

// Faster C++ solution for the same problem (measured speedup: 1.6864423689911312x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}
// Slower C++ solution:
#include <bits/stdc++.h>

using namespace std;



using VS = vector<string>;    using LL = long long;

using VI = vector<int>;       using VVI = vector<VI>;

using PII = pair<int, int>;   using PLL = pair<LL, LL>;

using VL = vector<LL>;        using VVL = vector<VL>;



#define ALL(a)  begin((a)),end((a))

#define RALL(a) (a).rbegin(), (a).rend()

#define PB push_back

#define EB emplace_back

#define MP make_pair

#define SZ(a) int((a).size())

#define SORT(c) sort(ALL((c)))

#define RSORT(c) sort(RALL((c)))

#define UNIQ(c) (c).erase(unique(ALL((c))), end((c)))

#define FOR(i, s, e) for (int(i) = (s); (i) < (e); (i)++)

#define FORR(i, s, e) for (int(i) = (s); (i) > (e); (i)--)

#define debug(x) cerr << #x << ": " << x << endl

const int INF = 1e9;                          const LL LINF = 1e16;

const LL MOD = 1000000007;                    const double PI = acos(-1.0);

int DX[8] = { 0, 0, 1, -1, 1, 1, -1, -1 };    int DY[8] = { 1, -1, 0, 0, 1, -1, 1, -1 };



/* -----  2018/02/14  Problem: 073_abc_c / Link: https://abc073.contest.atcoder.jp/tasks/abc073_c?lang=en  ----- */

/* ------問題------







-----問題ここまで----- */

/* -----解説等-----







----解説ここまで---- */



LL N;



LL ans = 0LL;



int main() {

	cin.tie(0);

	ios_base::sync_with_stdio(false);



	cin >> N;

	map<LL, LL>Map;

	FOR(i, 0, N) {

		LL a; cin >> a;

		Map[a]++;

	}



	for (map<LL, LL>::iterator it = Map.begin(); it != Map.end(); it++) {

		if ((*it).second % 2 == 1)ans++;

	}

	cout << ans << "\n";



	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.73423923789227x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;



int a[10000000];



int main()

{

    int n,c=0,b=1,i,j;

    scanf("%d",&n);

    for(i=0; i<n; i++)

    {

        scanf("%d",&a[i]);

    }

    sort(a,a+n);

    for(i=0; i<n-1; i++)

    {

        if(a[i]==a[i+1])

        {

            ++b;

        }

        else

        {

            if(b%2==1)

                ++c;

            b=1;

        }

    }

    b = b-1;

    if(a[n-1]!=a[n-2])

        ++c;

    else if(a[n-1]==a[n-2] && (b%2==0))

        ++c;



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

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 1.6721300411236282x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

using ll = long long;

const int maxn = 1e5 + 10;



int vec[maxn];



string s[] = {"Adrian", "Bruno", "Goran"};

int ans[3];



int main() {

    int n, m;

    set<int> s;

    scanf("%d", &n);

    while(n--) {

        scanf("%d", &m);

        if(s.count(m)) s.erase(m);

        else s.insert(m);

    }

    printf("%d\n", s.size());

}

// Faster C++ solution for the same problem (measured speedup: 1.7033312651567272x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}
// Slower C++ solution:
#include <iostream>

#include<vector>

#include<algorithm>

#include<map>

#include<set>

#include<string>

#include<math.h>



using namespace std;



struct node{

 int x;

 int time;

 bool operator <(node &B)

 {

     if(time<B.time) return true;

     if(time==B.time) return x<B.x;

     return false;

 }

};

int main()

{

    int n;cin>>n;

    set<int>nums;

    for(int i=0;i<n;i++)

{

    int a;

    cin>>a;

    if(nums.count(a))

    {

        nums.erase(a);

    }else

    nums.insert(a);

}

cout<<nums.size()<<endl;





return 0;

}




// Faster C++ solution for the same problem (measured speedup: 1.7104701741986839x):
#include<stdio.h>

#include<string.h>

#include<algorithm>

using namespace std;

int a[120000];

int b[100000];

int main()

{

    int n;

    scanf("%d",&n);

    for(int i=0; i<n; i++)

        scanf("%d",&a[i]);

    sort(a,a+n);

    memset(b,0,sizeof(b));

    int s=0,j=0;

    for(int i=0; i<n; i++)

    {

        b[j]++;

        while(a[i]==a[i+1])

        {

            b[j]++;

            i++;

        }

        if(b[j]&1)

            s++;

        j++;

    }

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

    return 0;

}