author = "jaykm" n=input() ls=map(int,raw_input().split()) fewfew = "dqf2e" qed = "deqwd " wdefew = "deq d" ffewf = "dsq sd e" qwe = "qdwEFE" cttt=[0 for i in xrange(110)] for i in xrange(n): cttt[ls[i]]+=1 #print ct total=float("-inf") for i in xrange(101): total=max(total,cttt[i]+cttt[i+1]) print total author = "jaykm"