import sys def main(): n = (input()) s = (input()) a = [int(i) for i in input().split(' ')] Len = len(a) a.sort() Sum = 0 Count = 0 for i in range(Len): Sum +=int(a[i]) Count +=1 if Sum >= s: break for i in range(Len): ...