import sequtils, strutils, tables let _, a = stdin.readLine.split.map parseInt cntT = a.toCountTable x = cntT.values.toSeq.foldl(a + b div 2, 0) echo x