87262024-01-26 18:23:43NagyLeoKiváló számok 2pypy3Wrong answer 0/1001.103s87208 KiB
MOD = 10**9 + 7

def count_excellent_2():
    _ = int(input().strip())

    for __ in range(_):
        N = int(input().strip())
        last = 0
        for i in range(1, N+1):
            if i % 2 == 0:
                last = last*2+2
            else:
                last = last*2-2

        print(f"{last % MOD}")

count_excellent_2()
SubtaskSumTestVerdictTimeMemory
subtask10/0
1Wrong answer41ms76496 KiB
subtask20/13
2Wrong answer48ms76756 KiB
3Wrong answer43ms77100 KiB
subtask30/24
4Wrong answer50ms86476 KiB
5Wrong answer50ms86920 KiB
6Wrong answer50ms86624 KiB
7Wrong answer50ms87208 KiB
subtask40/34
8Time limit exceeded1.062s32600 KiB
9Time limit exceeded1.059s32776 KiB
10Time limit exceeded1.059s31684 KiB
11Time limit exceeded1.047s32456 KiB
subtask50/29
12Time limit exceeded1.055s36804 KiB
13Time limit exceeded1.054s36896 KiB
14Time limit exceeded1.103s37720 KiB
15Time limit exceeded1.054s36996 KiB
16Time limit exceeded1.049s37288 KiB
17Time limit exceeded1.059s37240 KiB
18Time limit exceeded1.064s37500 KiB