n,*a=$<.read.split.map &:to_i;s=0;p a.uniq.each{|i|c=a.count i;s+=c/2;c&1>0}.size/4+s