TWO

0

0 votes
Problem

#include<iostream>

#include<cstdio>

#include<math.h>

using namespace std;

#define m 10000LL


int main()
{
    int n,t,sum;
    scanf("%d",&n);
    while(n--)
    {
       sum=0;
       scanf("%d",&t);
       for(int i=0;i<=t;i++)
       {
         sum=sum+(1<<i);
         sum=sum%m;
       }
       cout<

    }

    return 0;
}

input example
2
0
1


constraints

m = 1298074214633706835075030044377087
1<=n<=500
0<=t<=500

Time Limit: 1
Memory Limit: 256
Source Limit:
Editor Image

?