Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- void convert_to_oct(int number)
- {
- if(number) {
- convert_to_oct(number/8);
- printf("%d",number%8);
- }
- }
- int main()
- {
- int liczba;
- printf("Podaj liczbe\n");
- scanf("%d", &liczba);
- convert_to_oct(liczba);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement