제출 #800584

#제출 시각아이디문제언어결과실행 시간메모리
800584FEDIKUS비스킷 담기 (IOI20_biscuits)C++17
42 / 100
1066 ms23900 KiB
#include "biscuits.h" #include<bits/stdc++.h> using namespace std; using ll = long long; ll count_tastiness(ll x, vector<ll> a){ map<ll,ll> da; da[0]=1; for(int i=0;i<60;i++) a.push_back(0); for(int i=0;i<a.size();i++){ map<ll,ll> nov; for(auto j:da){ nov[(j.first+a[i])/2]+=j.second; if(j.first+a[i]>=x) nov[(j.first+a[i]-x)/2]+=j.second; } da=nov; } ll ret=0; for(auto i:da) ret+=i.second; return ret; }

컴파일 시 표준 에러 (stderr) 메시지

biscuits.cpp: In function 'll count_tastiness(ll, std::vector<long long int>)':
biscuits.cpp:11:15: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   11 |  for(int i=0;i<a.size();i++){
      |              ~^~~~~~~~~
#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...