-Code
for _ in range(int(input())):
total_set = list(map(int, input().split()))
usa = total_set[:3]
rua = total_set[3:]
count = sum(usa) > sum(rua)
color = False
for i in range(3):
if usa[i] > rua[i]:
color = True
break
elif usa[i] < rua[i]:
break
else:
continue
if color and count:
res = "both"
elif color and not count:
res = "color"
elif not color and count:
res = "count"
else:
res = "none"
print(*total_set)
print(res)
print()
'Beakjoon&프로그래머스 > 파이썬' 카테고리의 다른 글
[백준/파이썬] 23901번 Bike Tour (0) | 2023.11.28 |
---|---|
[백준/파이썬] 25830번 Microwave Mishap (0) | 2023.11.27 |
[백준/파이썬] 29895번 Jõululaul (1) | 2023.11.25 |
[백준/파이썬] 30642번 아이그루스와 화장실 (0) | 2023.11.24 |
[백준/파이썬] 25829번 Presidential Election (1) | 2023.11.23 |