Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main() {
- int kusur;
- scanf("%d", &kusur);
- int desetki = kusur / 10;
- kusur = kusur - (desetki * 10);
- int petki = kusur / 5;
- kusur = kusur - (petki * 5);
- int dvojki = kusur / 2;
- kusur = kusur - (dvojki * 2);
- int edinici = kusur;
- printf("%d moneti od 10 denari\n", desetki);
- printf("%d moneti od 5 denari\n", petki);
- printf("%d moneti od 2 denari\n", dvojki);
- printf("%d moneti od 1 denar\n", edinici);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement