I added this to main
printf("Number of digits in 153: %d\n", digitn(153));
printf("Sum of digits in 153: %d\n", sum(153,digitn(153)));
printf("Number of digits in 10: %d\n", digitn(10));...
Type: Posts; User: stahta01
I added this to main
printf("Number of digits in 153: %d\n", digitn(153));
printf("Sum of digits in 153: %d\n", sum(153,digitn(153)));
printf("Number of digits in 10: %d\n", digitn(10));...
Learn what "\n" means; add it to all of your printf, Or use flush stdout. This might not be problem, but not sure it is not a problem.
Learn to indent correctly.
Learn to comment your code....