TOPIC
runtime error, but why?
ambabo asked 3 years ago
times = input()
universities = input() bring_univ = universities.replace(" ",",")
separated_univ = [(int(x.strip())) for x in bring_univ.split(',')]
soma = 0
for v in separated_univ: if v % 3 == 0: soma += v else: while v % 3 != 0: v -= 1 soma += v
print(soma)
This topic was solved and cannot recieve new replies.