
def solution(absolutes, signs):
total = 0
for i in range(0,len(absolutes)):
if signs[i] == True:
total += absolutes[i]
else:
total += (absolutes[i] * (-1))
return total'코딩테스트 > Python' 카테고리의 다른 글
| [프로그래머스/Python] 나누어 떨어지는 숫자 배열 (0) | 2025.09.24 |
|---|---|
| [프로그래머스/Python] 없는 숫자 더하기 (0) | 2025.09.24 |
| [프로그래머스/Python] 하샤드 수 (0) | 2025.09.24 |
| [프로그래머스/Python] 정수 제곱근 판별 (0) | 2025.09.23 |
| [프로그래머스/Python] 문자열 내 p와 y의 개수 (0) | 2025.09.22 |