# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
999262 | AliHasanli | Go (COCI16_go) | C++17 | 1 ms | 604 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
int main(){
int n,ans=0,curmax=-1;
string ans2;
cin>>n;
while(n--)
{
string s;
cin>>s;
int a,b,c;
cin>>a>>b;
c=b/(a-2);
if(c>0 && b%(a-2)<=1)
c--;
ans+=c;
if(curmax<c)
{
curmax=c;
ans2=s;
}
}cout<<ans<<endl<<ans2<<endl;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |