Showing posts with label Find Generic root of number. Show all posts
Showing posts with label Find Generic root of number. Show all posts

Find Generic root of number


#include <stdio.h>
int main()
{        

int num,i;
printf("Enter any number: ");
scanf("%d",&num);
printf("Generic root: %d", (i = num % 9) ? i : 9);
return 0;
}

Labels