# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
20002 |
2016-02-25T08:21:26 Z |
yukariko |
동전 (kriii4_E) |
C++ |
|
0 ms |
1720 KB |
#include <bits/stdc++.h>
using namespace std;
#define MOD 1000000007
typedef long long lld;
lld f(int n){
if(n < 3) return 1;
n -= 2;
lld r = (1LL<<n);
if(n>3) r -= (1LL<<(n-3));
return r;
}
int main(){
int n;
while(~scanf("%d", &n))
printf("%lld\n", f(n));
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
1720 KB |
Output is correct |
2 |
Correct |
0 ms |
1720 KB |
Output is correct |
3 |
Correct |
0 ms |
1720 KB |
Output is correct |
4 |
Correct |
0 ms |
1720 KB |
Output is correct |
5 |
Correct |
0 ms |
1720 KB |
Output is correct |
6 |
Correct |
0 ms |
1720 KB |
Output is correct |
7 |
Incorrect |
0 ms |
1720 KB |
Output isn't correct |
8 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Halted |
0 ms |
0 KB |
- |