write a program to input a number and display it is palprime or not.
Please
Answers
Answered by
6
Answer:
Logic to find first and last digit of a number
Input a number from user. Store it in some variable say num . Find last digit using modulo division by 10 i.e. lastDigit = num % 10 . To find first digit we have simple formula firstDigit = n / pow(10, digits - 1)
Explanation:
Similar questions