AcWing 653. 钞票
原题链接
中等
作者:
涅槃
,
2020-02-24 13:01:37
,
所有人可见
,
阅读 667
#include <cstdio>
int main()
{
int t;
int a,b,c,d,e,f,g;
scanf("%d",&t);
a=t/100;
b=t%100/50;
c=t%100%50/20;
d=t%100%50%20/10;
e=t%100%50%20%10/5;
f=t%100%50%20%10%5/2;
g=t%100%50%20%10%5%2/1;
printf("%d\n",t);
printf("%d nota(s) de R$ 100,00\n",a);
printf("%d nota(s) de R$ 50,00\n",b);
printf("%d nota(s) de R$ 20,00\n",c);
printf("%d nota(s) de R$ 10,00\n",d);
printf("%d nota(s) de R$ 5,00\n",e);
printf("%d nota(s) de R$ 2,00\n",f);
printf("%d nota(s) de R$ 1,00\n",g);
return 0;
}
兄弟们这波很暴力