delete pics to save space

This commit is contained in:
2023-08-03 09:22:52 +08:00
commit de60cd6ed4
1334 changed files with 66221 additions and 0 deletions

41
2.1591.cpp Normal file
View File

@ -0,0 +1,41 @@
#include<cstdio>
#include<cstring>
const int MAXN=31;
long long N,K,temp;
int Sp,Sq,minA,minB,A,B;
bool first;
int main()
{
#ifdef local
freopen("pro.in","r",stdin);
#endif
while(scanf("%d%d%d",&N,&Sp,&Sq)==3)
{
first=true;
minA=minB=0;
for(A=0;A<=MAXN;A++)
{
for(B=0;B<=MAXN;B++)
{
temp=0;
temp=(((N-1)*Sp+(((N-1)*Sp)<<A))>>B)+Sq;
if(temp<Sq*N) break;
if(first)
{
K=temp;
minA=A;
minB=B;
first=false;
}
else if(K>temp)
{
K=temp;
minA=A;
minB=B;
}
}
}
printf("%lld %d %d\n",K,minA,minB);
}
return 0;
}