알고리즘

[프로그래머스] 음양 더하기

hminor 2023. 6. 27. 12:25
def solution(absolutes, signs): 
	return sum([absolutes[i] if signs[i] else -absolutes[i] for i in range(len(signs))])