标签:ring string 决定 rac space int ted 一点 miss
2 900 250
0 50
Ignatius.L
#include<stdio.h>
#include<string.h>
#define M
int main(){
int t,n;
scanf("%d",&t);
while(t--){
scanf("%d",&n);
int sum=0;
for(int i=0;i<=n/150;i++)
for(int j=0;j<=n/200;j++)
for(int k=0;k<=n/350;k++){
int temp=i*150+j*200+k*350;
if(sum<temp && temp<=n)
sum=temp;
}
printf("%d\n",n-sum);
}
return 0;
}
标签:ring string 决定 rac space int ted 一点 miss
原文地址:http://www.cnblogs.com/liguangsunls/p/7225537.html