fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int num;
  5. int ten,five,one;
  6. scanf("%d",&num);
  7. ten=num/10;
  8. num=num-ten*10;
  9. five=num/5;
  10. num=num-five*5;
  11. one=num/1;
  12. printf("ten:%d \nfive:%d \none:%d",ten,five,one);
  13. return 0;
  14. }
  15.  
Success #stdin #stdout 0s 4668KB
stdin
109
stdout
ten:10 
five:1 
one:4