On Sunday, May 3, 2020 at 4:26:21 AM UTC+2, Leon H wrote:
>
> def main():
>     num_cases = int(input())
>     U = int(input())
>     for i in range(num_cases):
>

The problem is that reach case starts with its own "U" value.
So you want

    for i in range(num_cases):
        U = int(input())

Otherwise, your solution looks good!
-- 
Simon.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Code Jam" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-code+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-code/ed42bfef-7268-4876-9e9a-a2f8a4a0e790%40googlegroups.com.

Reply via email to