import itertools as it n,k= map(int,input().split()) a= list(map(int,input().split())) ans= 0 num= list(it.combinations(a,k)) for i in range(len(num)): x= sum(num[i]) if (x % 99824453) <= (x % 998): ans += 1 print(ans % 998)