WORKSHEET-3 1. 1.Write a C program to count number of digits in a number.
2. Write a C program to calculate product of digits of a
number. 3. Write a C program to check whether a number is palindrome or not. Note: A palindromic that remains the same when its digits are reversed .
4. Write a C program to find power of a number (xn )
using for loop and without using math function pow(). 5. Write a C program to calculate factorial of a number.
6. Write a C program to find all factors of a number.
7. Write a C program to find H CF (GCD) of two numbers. 8. Write a C program to check whether a number is Perfect number or not. Note: perfect number is a positive integer that is equal to the sum of its positive divisors, excluding the number itself. For instance, 6 has divisors 1, 2 and 3 (excluding itself), and 1 + 2 + 3 = 6, so 6 is a perfect number.
9. Write a C program to find sum of first and last digit of a
number. 10.Write a C program to find frequency of a digit input by a user in a given integer.