# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
400351 | 2021-05-07T22:01:11 Z | REALITYNB | 비스킷 담기 (IOI20_biscuits) | C++14 | 2 ms | 332 KB |
#include <bits/stdc++.h> #include "biscuits.h" #define int long long using namespace std; int count_tastiness(int x ,vector<int> a){ int n =a.size()*2; while(a.size()!=n) a.push_back(0) ; vector<int> dp(n+1) ; dp[n]=1; for(int i=0;i<n;i++){ vector<int> b = a ; int stop=i; for(int j=i;j<n;j++){ if(b[j]>1){ b[j+1]+=b[j]/2 ; if(b[j]&1) b[j]=1; else b[j]=0; stop=j+1; } else break ; } for(int j=i;j<stop;j++){ if(b[j]==1){ dp[i]+=dp[stop]*(1<<(j-i)) ; } } } return dp[0] ; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 208 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 204 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 204 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 332 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 208 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |