Problem:
 Score : 300 points    Problem Statement You are playing the following game with Joisino.   Initially, you have a blank sheet of paper.  Joisino announces a number. If that number is written on the sheet, erase the number from the sheet; if not, write the number on the sheet. This process is repeated N times.  Then, you are asked a question: How many numbers are written on the sheet now?   The numbers announced by Joisino are given as A_1, ... ,A_N in the order she announces them. How many numbers will be written on the sheet at the end of the game?      Constraints  1≤N≤100000  1≤A_i≤1000000000(=10^9)  All input values are integers.         Input Input is given from Standard Input in the following format:  N  A_1  :  A_N       Output Print how many numbers will be written on the sheet at the end of the game.        Sample Input 1 3
6
2
6      Sample Output 1 1  The game proceeds as follows:    6 is not written on the sheet, so write 6 .    2 is not written on the sheet, so write 2 .    6 is written on the sheet, so erase 6 .    Thus, the sheet contains only 2 in the end. The answer is 1 .       Sample Input 2 4
2
5
5
2      Sample Output 2 0  It is possible that no number is written on the sheet in the end.       Sample Input 3 6
12
22
16
22
18
12      Sample Output 3 2

Solution (Python):
import sys
N = int(input())
A = []
for _ in range(N):
    A.append(int(input())) 



if N == 1:
    print(1)
    sys.exit()

if set(A) == 1:
    print(0)
    sys.exit()

A = sorted(A)


count = 1
ans = 0
firstnum = A[0] 
for i in range(1,N):
    if firstnum == A[i]:
        count = count + 1
    else:
        if count % 2 == 0:
            count = 1
        else:
            ans = ans + 1
            count = 1

    firstnum = A[i]  

if count%2 == 0:
  ans = ans +0
else:
  ans = ans + 1
print(ans)

Solution (Python):
n=int(input())
s=set()
for i in range(n):
    s^={input()}
print(len(s))

Solution (Python):
from collections import Counter

n = int(input())
a = [int(input()) for _ in range(n)]
cnt = 0

for i, n in Counter(a).items():
    if n % 2 == 1:
        cnt += 1

print(cnt)

Solution (Python):

N = int(input())
A = [int(input()) for i in range(N)]
ans = set()
for i in A:
    if i in ans:
        ans.discard(i)
    else:
        ans.add(i)
print(len(ans))

Solution (Python):
from collections import defaultdict
dic = defaultdict(int)

N = int(input())
for _ in range(N):
    v = int(input())
    dic[v] += 1

count = 0
for k, v in dic.items():
    if v%2:
        
        count += 1
    else:
        
        pass
print(count)

Solution (Python):
from collections import defaultdict

d = defaultdict(int)
n = int(input())
for i in range(n):
    x = int(input())
    d[x] += 1
ans = 0
for key, value in d.items():
    if value % 2 == 1:
        ans += 1
print(ans)

Solution (Python):
import sys
N = int(input())
A = [int(input()) for _ in range(N)]
A.sort()
ans = 0
a = A[0]
n = 0
if N == 1:
    print(1)
    sys.exit()
for i in range(N):
    if a == A[i]:
        n += 1
    else:
        if n % 2 == 1:
            ans += 1
        n = 1
        a = A[i]
    
if A[-1] == A[-2] and n % 2 == 1:
    ans += 1
elif A[-1] != A[-2] and n % 2 == 1:
    ans += 1
print(ans)

Solution (Python):
import collections
n = int(input())
ls = [int(input()) for i in range(n)]
ls.sort()
c = collections.Counter(ls)
d = list(c)
p = 0
for j in range(len(c)):
    if c[d[j]] % 2 ==0:
        continue
    else:
        p += 1
print(p)

Solution (Python):
import collections
n = int(input())
ls = [int(input()) for i in range(n)]
ls.sort()
c = collections.Counter(ls)
d = list(c)
p = 0
for j in range(len(c)):
    if c[d[j]] % 2 ==0:
        continue
    else:
        p += 1
print(p)

Solution (Python):
from collections import Counter

n=int(input())
a=[int(input()) for _ in range(n)]

counter = Counter(a)
ans=0
for key in counter:
    if counter[key]%2==1:
        ans+=1
print(ans)

Solution (Python):
N=int(input())
A=set()
for i in range(N):
    a=int(input())
    if a in A:
        A.remove(a)
    else:
        A.add(a)
print(len(A))

Solution (Python):
def main():
  N = int(input())
  dic = {}
  for i in range(N):
    a = int(input())
    if dic.get(a):
      dic[a] += 1
    else:
      dic[a] = 1
  ans = 0
  for val in dic.values():
    if val % 2 == 1:
      ans += 1
  print(ans)

if  __name__ == "__main__":
  main()

Solution (Python):
n = int(input())
a = [int(input()) for _ in range(n)]

ans = set()
for i in a:
    ans ^= {i}
print(len(ans))

Solution (Python):
import sys
from collections import defaultdict
input = sys.stdin.readline

 
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))

n = I()
d = defaultdict(int)
for i in range(n):
    temp = I()
    d[temp] += 1
ans = 0
for i in d.values():
    if i % 2 == 1:
        ans += 1
        
print(ans)

Solution (Python):
N = int(input())
dictA = {}
for x in range(N):
    k = int(input())
    dictA.setdefault(k, 0)
    dictA[k] += 1
count = 0
for y in dictA.values():
    if y % 2 == 1:
        count += 1
print(count)

Solution (Python):
import sys
from collections import Counter

input = sys.stdin.readline


def main():
    N = int(input())
    A = [0] * N
    for i in range(N):
        A[i] = int(input())

    c = Counter(A)
    ans = 0
    for v in c.values():
        if v % 2 == 1:
            ans += 1

    print(ans)


if __name__ == "__main__":
    main()

Solution (Python):
N,*A=map(int,open(0))
import collections
C=collections.Counter(A)
print(sum(v%2>0 for v in C.values()))

Solution (Python):
n = int(input())
d = {}

for i in range(n):
  temp = "key" + input()
  if temp in d:
    del d[temp]

  else:
    d[temp] = 1

ans = 0
for i in d:
  ans += d[i]
  
print(ans)

Solution (Python):
n = int(input())
kami = set([])
for i in range(n):
	a = input()
	if a in kami:
		kami.remove(a)
	else:
		kami.add(a)
print(len(kami))

Solution (Python):
import re
import sys
from bisect import bisect, bisect_left, insort, insort_left
from collections import Counter, defaultdict, deque
from copy import deepcopy
from fractions import gcd
from itertools import (
    accumulate, combinations, combinations_with_replacement, groupby,
    permutations, product)
from math import (
    acos, asin, atan, ceil, cos, degrees, factorial, hypot, log2, pi, radians,
    sin, sqrt, tan)
from operator import itemgetter, mul
from string import ascii_lowercase, ascii_uppercase, digits


def inp():
    return(int(input()))


def inlist():
    return(list(map(int, input().split())))


def instr():
    s = input()
    return(list(s[:len(s)]))


def invr():
    return(map(int, input().split()))


count = dict()

n = inp()

for _ in range(n):
    a = inp()
    if a in count:
        count[a] += 1
    else:
        count[a] = 1

c = 0

for key in count:
    c += count[key] % 2
print(c)

Solution (Python):
N, *A = map(int, open(0).read().split())
d = dict()
for a in A:
    d[a] = d.get(a, 0) ^ 1
print(sum(d.values()))

Solution (Python):
N = int(input())
d = dict()
for _ in range(N):
    a = int(input())
    d[a] = d.get(a, 0) ^ 1
print(sum(d.values()))

Solution (Python):
import collections
n = int(input())

l = []
for i in range(n):
    l.append(int(input()))
    
a = collections.Counter(l)
cnt = 0
for k,v in a.items():
    if v%2 != 0:
        cnt += 1

print(cnt)

Solution (Python):
N = int(input())

adict = {}

for i in range(N):
  A = int(input())
  if A not in adict:
    adict[A] = True
  else:
    adict[A] = not adict[A]
    
ans = 0
for key in adict:
  if adict[key]:
    ans += 1
print(ans)

Solution (Python):
n = int(input())
A = [0]*n
for i in range(n):
    A[i] = int(input())
paper = set()
for a in A:
    if a in paper:
        paper.remove(a)
    else:
        paper.add(a)
print(len(paper))

Solution (Python):

from collections import Counter
n = int(input())
a = []
for _ in range(n):
    a.append(int(input()))
  
cnt = 0
c = Counter(a)
for i in c.values():
    if i % 2 == 0:
        continue
    else:
        cnt += 1
        
print(cnt)

Solution (Python):
n = int(input())
ans = set()
for _ in range(n):
    ans^={input()}
print(len(ans))

Solution (Python):
from collections import Counter
n=int(input())
a=[int(input()) for _ in range(n)]
ans=0
C=Counter(a)

for k,v in C.items():
    if v%2==1:
        ans+=1
print(ans)

Solution (Python):
from collections import Counter


def main():
    n = int(input())
    a = []
    for i in range(n):
        a.append(int(input()))
    counter = Counter(a)
    ans = 0
    for key, value in counter.items():
        if value % 2 == 1:
            ans += 1
    print(ans)


main()

Solution (Python):
from collections import Counter
N = int(input())
A = []
ans = 0
for i in range(N):
    A.append(int(input()))

c = Counter(A)
v = list(c.values())
for i in v:
    if i % 2 == 1:
        ans += 1
print(ans)

Solution (Python):
from collections import *
N=int(input())
A=[]
for i in range(0,N):
    A.append(int(input()))
M=Counter(A)
ans=0
for i in M:
    if(M[i]%2):
        ans+=1
print(str(ans))

Solution (Python):
from collections import *
N=int(input())
A=[]
for i in range(0,N):
    A.append(int(input()))
M=Counter(A)
ans=0
for i in M:
    if(M[i]%2):
        ans+=1
print(str(ans))

Solution (Python):
from collections import *
N=int(input())
A=[]
for i in range(0,N):
    A.append(int(input()))
M=Counter(A)
ans=0
for i in M:
    if(M[i]%2):
        ans+=1
print(str(ans))

Solution (Python):
import sys
import math

if sys.platform =='ios':
    sys.stdin=open('input_file.txt')
   
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N=int(input())
cnt=0
li=[]

for _ in range(N):
	li.append(int(input()))
	
so=sorted(li)
ct=1

for i in range(N-1):
	if so[i]==so[i+1]:
		ct+=1
	else:
		cnt+=ct%2
		ct=1
		
cnt+=ct%2



if N==1:
	print(1)
else:	
	print(cnt)

Solution (Python):
N=int(input())
S=set()

for n in range(N):
    _=int(input())
    if _ in S:
        S.remove(_)
    else:
        S.add(_)

print(len(S))

Solution (Python):
N=int(input())
s=set([])
for i in range(N):
  t=input()
  if t not in s:
    s.add(t)
  else:
    s.remove(t)
print(len(s))

Solution (Python):
from collections import defaultdict


def main():
    N = int(input())
    A = [int(input()) for _ in range(N)]

    ans = defaultdict(int)
    for a in A:
        if a in ans:
            ans.pop(a)
        else:
            ans[a] += 1

    print(len(ans))


if __name__ == "__main__":
    main()

Solution (Python):
import sys
input = sys.stdin.readline
from collections import Counter


def read():
    N = int(input().strip())
    A = []
    for i in range(N):
        a = int(input().strip())
        A.append(a)
    return N, A


def solve(N, A):
    count = Counter(A)
    ans = 0
    for v in count.values():
        if v % 2 == 1:
            ans += 1
    return ans


if __name__ == '__main__':
    inputs = read()
    print(solve(*inputs))

Solution (Python):
n=int(input())
a=[int(input()) for _ in range(n)]
from collections import Counter
c=Counter(a)
print(len(list(filter(lambda x: x%2==1, c.values()))))

Solution (Python):
N = int(input())
A = []
B = []
for i in range(N):
  A.append(int(input()))
  
A.sort()
B.append(1)

for i in range(1, N):
  if(A[i]!= A[i- 1]):
    B.append(1)
  else:
    B[-1]+= 1
  i+= 1
  
ans = list(filter(lambda x: x % 2 == 1, B))

print(len(ans))

Solution (Python):
from collections import defaultdict

d = defaultdict(int)
N =int(input())
for i in range(N):
  a = int(input())
  d[a] += 1

ans = 0
for a in d:
  ans += d[a] % 2

print(ans)

Solution (Python):
from collections import Counter
N = int(input())
a_counter = Counter([int(input()) for _ in range(N)])

ans = 0
for num, cnt in a_counter.items():
  if cnt % 2 == 1:
    ans += 1

print(ans)

Solution (Python):
from collections import defaultdict

d = defaultdict(int)

N = int(input())
for i in range(N):
    d[int(input())] += 1

ans = sum([1 for i in d.values() if i % 2 == 1])
print(ans)

Solution (Python):
from collections import Counter


N, *A = map(int, open(0).read().split())
ans = 0
for v in Counter(A).values():
    if v % 2:
        ans += 1
print(ans)

Solution (Python):
n = int(input())

d = {}
ans = 0

for _ in range(n):
    a = int(input())
    if a in d:
        d[a] += 1
    else:
        d[a] = 1

for k,v in d.items():
    if v % 2 == 1:
        ans += 1

print(ans)

Solution (Python):
n = int(input())
as_ = [int(input()) for _ in range(n)]

data = set()

for a in as_:
    if a not in data:
        data.add(a)
    else:
        data.remove(a)

print(len(data))

Solution (Python):
import collections
n=int(input())
a=[int(input()) for i in range(n)]
b=collections.Counter(a)
count=0
for k,v in b.items():
  if v%2!=0:
    count+=1
print(count)

Solution (Python):
import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush
from math import *
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction



mod = int(pow(10, 9) + 7)
mod2 = 998244353
def data(): return sys.stdin.readline().strip()
def out(*var, end="\n"): sys.stdout.write(' '.join(map(str, var))+end)
def l(): return list(sp())
def sl(): return list(ssp())
def sp(): return map(int, data().split())
def ssp(): return map(str, data().split())
def l1d(n, val=0): return [val for i in range(n)]
def l2d(n, m, val=0): return [l1d(n, val) for j in range(m)]






N=l()[0]
s=set()
for i in range(N):
    a=l()[0]
    if(a in s):
        s.discard(a)
    else:
        s.add(a)
print(len(s))

Solution (Python):
n = int(input())
A = [int(input()) for i in range(n)]
count = 0
from collections import Counter
C = Counter(A)
for v in C.values():
	if v % 2:
		count += 1
print(count)

Solution (Python):
n = int(input())
A = [int(input()) for i in range(n)]
count = 0
from collections import Counter
C = Counter(A)
for k in C.keys():
	if C[k] % 2:
		count += 1
print(count)

Solution (Python):
from collections import defaultdict
note = defaultdict(int)
for _ in range(int(input())):
    note[input()] ^= 1
print(sum(note.values()))

Solution (Python):
N = int(input())
d={}
for _ in range(N):
    n = int(input())
    if not n in d:
        d[n] = 1
    d[n]*=-1
print(list(d.values()).count(-1))

Solution (Python):
n = int(input())
ab = [int(input()) for _ in range(n)] 

sab = set(ab)

import collections
c = collections.Counter(ab)
res = 0
for i in sab:
    temp = c[i]%2
    res +=temp

print(res)

Solution (Python):
n = int(input().rstrip())
nums = [int(input().rstrip()) for _ in range(n)]

num_hash={}
for n in nums:
    if num_hash.get(n):
        num_hash[n] += 1
    else:
        num_hash[n] = 1

num_counter = 0
for k in num_hash.keys():
    if num_hash[k] %2 == 1:
        num_counter += 1
print(num_counter)

Solution (Python):
N=int(input())
A=[int(input()) for x in range(N)]
y=set()
for i in A:
    if i in y:
        y.remove(i)
    else:
        y.add(i)
print(len(y))

Solution (Python):
N=int(input())
A=[int(input()) for x in range(N)]
y=set()
for i in A:
    if i in y:
        y.remove(i)
    else:
        y.add(i)
print(len(y))

Solution (Python):
N=int(input())
A=[int(input()) for x in range(N)]
y=set()
for i in A:
    if i in y:
        y.remove(i)
    else:
        y.add(i)
print(len(y))

Solution (Python):
from collections import Counter
def main():
    n = int(input())
    A = [int(input()) for _ in range(n)]
    c = Counter(A)
    ans = 0
    for v in c.values():
        if v % 2 != 0:
            ans += 1
    print(ans)

if __name__ == '__main__':
    main()

Solution (Python):
from collections import Counter

N = int(input())
memo = []
for _ in range(N):
  memo.append(int(input()))

counter = Counter(memo)

ans = 0
for k, v in counter.items():
  if v % 2 != 0:
    ans += 1

print(ans)

Solution (Python):
from collections import Counter

N = int(input())
c = Counter(int(input()) for _ in range(N))
print(len(list(filter(lambda x: x % 2 == 1, c.values()))))

Solution (Python):


import sys






























def main():
    mod = 1000000007                
    inf = float('inf')              
    
    sys.setrecursionlimit(10**6)    
    def input(): return sys.stdin.readline().rstrip()
    def ii():    return int(input())
    def mi():    return map(int, input().split())
    def mi_0():  return map(lambda x: int(x)-1, input().split())
    def lmi():   return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():    return list(input())
    
    
    n = ii()
    memo = set()
    for _ in range(n):
        x = ii()
        if x in memo:
            memo.remove(x)
        else:
            memo.add(x)
    
    print(len(list(memo)))


if __name__ == "__main__":
    main()

Solution (Python):

import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil,pi
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
def SI(): return input().rstrip()
def printns(x): print('\n'.join(x))
def printni(x): print('\n'.join(list(map(str,x))))
inf = 10**17
mod = 10**9 + 7
n=I()
lis=[I() for i in range(n)]
c=Counter(lis)
count=0
for i in c.keys():
    if c[i]%2==1:
        count+=1
print(count)

Solution (Python):
import itertools

n = int(input())
A = [int(input()) for _ in range(n)]
A.sort()

count = 0
itrs = itertools.groupby(A)
for k, v in itrs:
    if len(list(v)) % 2 == 1:
        count += 1

print(count)

Solution (Python):
from collections import Counter
def solve():
    ans = 0
    N = int(input())
    A = [int(input()) for _ in range(N)]
    c = Counter(A)
    for k in c.values():
        if k%2==1:
            ans += 1
    return ans
print(solve())

Solution (Python):
n = int(input())
dict = {}
for _ in range(n):
  a = int(input())
  if a not in dict:
    dict[a] = True
  else:
    dict[a] = not dict[a]
cnt = 0
for v in dict.values():
  if v:
    cnt+=1
print(cnt)

Solution (Python):
n = int(input())

dic = {}
for i in range(n):
    tmp = int(input())
    if tmp not in dic:
        dic[tmp] = 1
    elif dic[tmp] == 1:
        dic[tmp] = 0
    else:
        dic[tmp] = 1

ans = 0
for k,v in dic.items():
    if v == 1:
        ans += 1

print(ans)

Solution (Python):
from collections import Counter


def main():
    N = int(input())
    A = [int(input()) for _ in range(N)]
    c = Counter(A)
    print(sum([v % 2 for v in c.values()]))


if __name__ == '__main__':
    main()

Solution (Python):
from collections import defaultdict
n = int(input())
d = defaultdict(int)
for i in range(n):
    d[int(input())] += 1

ans = 0
for i in d.values():
    ans += i%2

print(ans)

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]
dict = {}
count = 0
for i in a:
  if i not in dict:
    dict[i] = 1
  elif i in dict:
    dict[i]+= 1

for i in set(a):
  if dict[i]%2!=0:
    count += 1
    
    
print(count)

Solution (Python):
N = int(input())
A = set()
for i in range(N):
  x = int(input())
  if x in A:
    A.remove(x)
  else:
    A.add(x)
print(len(A))

Solution (Python):
n=int(input())
A=set()
for i in range(n):
    a=input()
    if a in A:
        A.remove(a)
    else:
        A.add(a)
print(len(A))

Solution (Python):
def getN():
    return int(input())
def getNM():
    return map(int, input().split())
def getList():
    return list(map(int, input().split()))
def getArray(intn):
    return [int(input()) for i in range(intn)]
def input():
    return sys.stdin.readline().rstrip()

from collections import defaultdict, deque, Counter
from sys import exit
import heapq
import math
import fractions
import copy
from itertools import permutations
from operator import mul
from functools import reduce
from bisect import bisect_left, bisect_right

import sys
sys.setrecursionlimit(1000000000)
mod = 10 ** 9 + 7

N = getN()
A = Counter(getArray(N))
cnt = 0
for i in A.values():
    if i % 2 == 1:
        cnt += 1
print(cnt)

Solution (Python):
import collections
N = int(input())
A = [int(input()) for _ in range(N)]
C = collections.Counter(A)
count = 0
for v in C.values():
    if v%2 != 0:
        count += 1
print(count)

Solution (Python):






N = int(input())
A = []
for _ in range(N):
    A.append(int(input()))





import collections





count = collections.Counter(A)
ans = 0
for d in count.values():
    if d%2 != 0:
        ans += 1
print(ans)

Solution (Python):
n = int(input())
A = [input() for _ in range(n)]
ans = 0

import collections
c = collections.Counter(A)

A = sorted(set(A))

for i in A:
    if c[i] % 2 == 1:
        ans += 1
        
print(ans)

Solution (Python):
N = int(input())

arr = [ int(input()) for i in range(N)]

arr.sort()
cnt = 0
num = 1

a = arr[0]

for i in range(1,N):
  if arr[i] == a:
    num += 1
  else:
    if num % 2 == 1:
      cnt += 1
    num = 1
    a = arr[i]
if num % 2 == 1:
  cnt += 1

print(int(cnt))

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]

result = set([])
for i in A:
    if i in result:
        result.remove(i)
    else:
        result.add(i)
print(len(result))

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = [INT() for _ in range(N)]	

dic = defaultdict(int)

for a in A:
	dic[a] ^= 1


print(sum([dic[x] for x in dic]))

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = [INT() for _ in range(N)]	

dic = defaultdict(int)

for a in A:
	dic[a] += 1


print(len([1 for x in dic if dic[x]%2]))

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = [INT() for _ in range(N)]	

dic = defaultdict(int)

for a in A:
	dic[a] += 1


print(len([1 for x in dic if dic[x]%2 == 1]))

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = [INT() for _ in range(N)]	

dic = dict()

for a in A:
	if a in dic:
		dic[a] ^= 1
	else:
		dic[a] = 1


ans = 0
for x in dic:
	ans += dic[x]
print(ans)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
A = [INT() for _ in range(N)]	

dic = defaultdict(int)

for a in A:
	
	dic[a] ^= 1


ans = 0
for x in dic:
	ans += dic[x]
print(ans)

Solution (Python):
N = int(input())
nums = {}
for _ in range(N):
    num = int(input())
    if num in nums:
        nums.pop(num)
    else:
        nums[num] = 0

print(len(nums))

Solution (Python):
import sys
input = sys.stdin.readline

from collections import Counter
N = int(input())
A = [int(input()) for _ in range(N)]
c = [x for x in Counter(A).values() if x % 2 == 1]
print(len(c))

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()

num = defaultdict(int)

for _ in range(N):
	A = INT()
	num[A-1] ^= 1

ans = 0
for x in num:
	ans += num[x]

print(ans)

Solution (Python):






import sys
input = sys.stdin.readline

import math

import bisect
from collections import defaultdict
from collections import deque
from functools import lru_cache






MOD = 10**9+7
INF = float('inf')






def I(): return int(input().strip())
def S(): return input().strip()
def IL(): return list(map(int,input().split()))
def SL(): return list(map(str,input().split()))
def ILs(n): return list(int(input()) for _ in range(n))
def SLs(n): return list(input().strip() for _ in range(n))
def ILL(n): return [list(map(int, input().split())) for _ in range(n)]
def SLL(n): return [list(map(str, input().split())) for _ in range(n)]


def P(arg): print(arg); return
def Y(): print("Yes"); return
def N(): print("No"); return
def E(): exit()
def PE(arg): print(arg); exit()
def YE(): print("Yes"); exit()
def NE(): print("No"); exit()


def DD(arg): return defaultdict(arg)



def inv(n): return pow(n, MOD-2, MOD)


kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret


def factorization(n):
  arr = []
  temp = n
  for i in range(2, int(-(-n**0.5//1))+1):
    if temp%i==0:
      cnt=0
      while temp%i==0: 
        cnt+=1 
        temp //= i
      arr.append([i, cnt])
  if temp!=1:
    arr.append([temp, 1])
  if arr==[]:
    arr.append([n, 1])
  return arr


def make_divisors(n):
  divisors = []
  for i in range(1, int(n**0.5)+1):
    if n % i == 0:
      divisors.append(i)
      if i != n // i: 
        divisors.append(n//i)
  return divisors


def gcd(a, b):
    while b:
        a, b = b, a % b
    return a


def lcm(a, b):
    return a * b // gcd (a, b)


def count_bit(n):
  count = 0
  while n:
    n &= n -1
    count += 1
  return count


def base_10_to_n(X, n):
  if X//n:
    return base_10_to_n(X//n, n)+[X%n]
  return [X%n]

def base_n_to_10(X, n):
  return sum(int(str(X)[-i])*n**i for i in range(len(str(X))))


def int_log(n, a):
  count = 0
  while n>=a:
    n = n//a
    count += 1
  if a**count == n:
    return count
  else:
    return count+1





N = I()
A = ILs(N)
d = DD(int)
for a in A:
  d[a] += 1
  
d = [(d[k])for k in d]

P(sum(1 if k%2 else 0for k in d))

Solution (Python):
n = int(input())
a = sorted([int(input()) for i in range(n)])
ans = 0
s = 1
for i in range(n - 1):
  if a[i] != a[i + 1]:
    ans += s % 2
    s = 1
  else:
    s += 1
ans += s % 2
print(ans)

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()

def resolve():
    n=int(input())
    l=[input() for i in range(n)]
    cnt=0
    from collections import Counter
    c=Counter(l)
    for i in c.values():
        if i%2==1:
            cnt+=1
    print(cnt)
resolve()

Solution (Python):
n = int(input())
d = {}
for _ in [0]*n:
    a = int(input())
    d[a] = d.get(a, 0)+1
print(sum(i%2 for i in d.values()))

Solution (Python):
N = int(input())
S = set()
for i in range(N):
  num = int(input())
  if num in S:
    S.remove(num)
  else:
    S.add(num)
print(len(S))

Solution (Python):
from collections import Counter
N = int(input())
A = [input() for _ in range(N)]

res = 0


c = Counter(A)
for i in c.values():
    res += i % 2
print(res)