(UPD: 2024-12-04 14:48 UTC) Judge is not working due to Cloudflare incident. (URL) We can do nothing about it, sorry. After the incident is resolved, we will grade all submissions.

Submission #1083842

#TimeUsernameProblemLanguageResultExecution timeMemory
1083842ZeroCoolPacking Biscuits (IOI20_biscuits)C++14
100 / 100
11 ms1468 KiB
#include "biscuits.h" #include <bits/stdc++.h> using namespace std; using ll = long long; const ll N = 60 + 2; const ll INF = 1e18; ll dp[N]; long long count_tastiness(long long x, std::vector<long long> A) { fill(dp, dp+N, 1); A.resize(N); for(int i = 1;i<N;i++)A[i] = (A[i] << i) + A[i-1]; for(int i = 0;i<N;i++){ ll k = INF; for(int j = i-1;j>=0;j--){ k = min(k, A[j]); if(x <= (k >> j)){ dp[i] += dp[j]; k -= (x << j); } } } return dp[N-1]; }
#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...