| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 5450 | sunyutong | 买小猫小狗 | C++ | Accepted | 100 | 0 MS | 248 KB | 207 | 2020-08-04 16:19:36 |
#include<bits/stdc++.h> using namespace std; int main(){ int x,a,b,ans=0; cin>>x>>a>>b; for (int dog=1; dog<=x/a; dog++) if (x-dog*a>0 && (x-dog*a)%b==0) ans++; cout<<ans<<endl; return 0; }