More actions
imported>jereneal20 No edit summary |
imported>jereneal20 No edit summary |
||
| Line 1: | Line 1: | ||
= Jump! Jump! = | = Jump! Jump! = | ||
* [http://www.algospot.com/judge/problem/read/JUMP Jump] | * [http://www.algospot.com/judge/problem/read/JUMP Jump] | ||
* 점화식. 3step까지 개수를 한번 체크해봐요. | |||
// | // | ||
// main.cpp | // main.cpp | ||
Latest revision as of 04:22, 8 August 2013
Jump! Jump!
- Jump
- 점화식. 3step까지 개수를 한번 체크해봐요.
//
// main.cpp
// codersHigh2013
//
// Created by Jereneal Kim on 13. 7. 30..
// Copyright (c) 2013년 Jereneal Kim. All rights reserved.
//
#include <iostream>
using namespace std;
int main(int argc, const char * argv[])
{
long long int sum;
int T,n;
scanf("%d",&T);
for(int iter=0;iter<T;iter++){
scanf("%d",&n);
n++;
sum = ((n-1)*n)/2 +1;
sum*=sum;
sum%=20130728;
printf("%lld\n",sum);
}
return 0;
}