https://school.programmers.co.kr/learn/courses/30/lessons/12982
def solution(d, budget): answer = 0 d.sort() for i in d: if budget - i >= 0: answer += 1 budget -= i return answer