Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int broi_cifri(int n)
- {
- if (n>0) return (1+broi_cifri(n/10));
- }
- int sbor_cifri(int n)
- {
- if (n>0) return (n%10+sbor_cifri(n/10));
- }
- int k_cifri(int n)
- {
- if (n/10>0 && n%10!=k )k_cifri(n/10);
- else if (n%10==k) return 1;
- else return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement