int main(int argc, char* argv[])
{
int x,y,z;
cout<<"test 1 - 100"<
{
bool run=true;
for(x=1;x<100*i&&run;++x)
for(y=1;y<20*i&&run;++y)
for(z=1;z<10*i&&run;++z)
{
if(18*x == 15*y && 15*y==20*z && (x+5*y+10*z)==100*i)
run=false;
}
if(!run)
cout< else cout<<" not ok:"< }
}
测试发现是80元的整数倍