Submission #1015993

#TimeUsernameProblemLanguageResultExecution timeMemory
1015993UnforgettableplPacking Biscuits (IOI20_biscuits)C++17
9 / 100
1080 ms48208 KiB
#include <bits/stdc++.h> using namespace std; const int LIMIT = 60; long long DP[LIMIT+2][100002]; long long count_tastiness(long long x, std::vector<long long> a) { DP[0][0]=1; a.resize(LIMIT+1); for(long long i=0;i<=LIMIT;i++){ for(long long j=0;j<=100000;j++){ DP[i+1][j] = DP[i][max(0ll,min(100001ll,2ll*(j-a[i])))] + DP[i][max(0ll,min(100001ll,2ll*(j-a[i]+x)))]; } } return DP[LIMIT+1][0]; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...