T = int(input())
answer = []
for test_case in range(1, T + 1):
result = 0
data = list(map(int, input().split()))
for i in range(len(data)):
if(data[i] % 2 != 0):
result += data[i]
answer.append(result)
for i in range(len(answer)):
print(f'#{i+1} {answer[i]}')
https://swexpertacademy.com/main/code/problem/problemDetail.do?contestProbId=AV5QSEhaA5sDFAUq
SW Expert Academy
SW 프로그래밍 역량 강화에 도움이 되는 다양한 학습 컨텐츠를 확인하세요!
swexpertacademy.com
728x90
'Algorithm&CodingTest > SW Expert Acardemy' 카테고리의 다른 글
[SWEA][D1] [2025] N줄 덧셈 - Python (0) | 2023.05.16 |
---|---|
[SWEA] [2046] 스탬프 찍기 - python (0) | 2023.05.16 |
[SWEA] [2047] 신문 헤드라인 - python (0) | 2023.05.16 |
[SWEA] [1938] 아주 간단한 계산기 - python (1) | 2023.05.16 |
[SWEA] [17299] 최소 덧셈 - python (0) | 2023.05.14 |