n,k=map(int,input().split()) a=sorted([i for i in map(int,input().split()) if i>0]) if len(a)