def solution(numbers, target): answer_list=[0] for i in numbers: temporary_list=[] #print("\nanswer_list:",answer_list) for j in answer_list: temporary_list.append(j+i) temporary_list.append(j-i) #print("tmp_list",temporary_list) answer_list=temporary_list #print("answer_list",answer_list) answer = answer_list.count(target) return answer 방법은 똑같았으나 구현하지 못해 내 코드는 아니지만 올린다.