Given a number, check whether the product of digit sum and reverse of digit sum equals the number or not.
Input : 1729 Output : Yes Explanation: digit sum = 1 + 7 + 2 + 9 = 19 Reverse of digit sum = 91 Product = digit sum * Reverse of digit sum = 19 * 91 = 1729 Input : 2334 Output : No
1. Find the sum of digits of given number.
2. Reverse the digit sum output.
3. Product of digit sum and reverse of digit sum.
If product equals to the original number then print “Yes” else print “No”.
This article is contributed by Dharmendra Kumar. If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above.
- Number formed by adding product of its max and min digit K times
- Maximum of sum and product of digits until number is reduced to a single digit
- Check if the first and last digit of number N is prime and their sum is less than K
- Check if given number contains a digit which is the average of all other digits
- Print all n-digit numbers whose sum of digits equals to given sum
- Count of n digit numbers whose sum of digits equals to given sum
- Check if the first and last digit of the smallest number forms a prime
- Check if product of digits of a number at even and odd places is equal
- Check whether product of digits at even places of a number is divisible by K
- Check if frequency of each digit is less than the digit
- Product of N with its largest odd digit
- Digit - Product - Sequence
- Counting numbers whose difference from reverse is a product of k
- Min steps to convert N-digit prime number into another by replacing a digit in each step
- Count of Numbers in Range where first digit is equal to last digit of the number
- First digit in product of an array of numbers
- Find the remainder when First digit of a number is divided by its Last digit
- Last digit of Product of two Large or Small numbers (a * b)
- Largest palindrome which is product of two N-digit numbers : Set 2
- Sum and Product of all even digit sum Nodes of a Singly Linked List