 Hello friends, I am Sanjay Gupta. In this video, I am going to demonstrate you how you can check whether the entered number is palindrome or not using recursion in C. Before starting, you can subscribe my YouTube channel by clicking on the link which is available at the bottom right corner of this video. You can download my app Techimus that is available on Google Play. You can connect with me by following these details which are available in front of you. Now coming onto the topic, you can see a code which is available in front of you. It is including two header files. First one is stdr.h. It is for printf and scanf. Second header file is math.h. It is for pow function. Then for checking of palindrome, I have declared a function that is reverse. So if a number which is entered by the user, if its reverse is equal to the original number, then that number is treated as palindrome. So for that purpose, I have declared a function reverse. It will receive two input which is of integer type and it will return an integer value. The main function is defined. It is declaring four variables, num, result, length and 10. Then using printf scanf, I am going to read a number whose I want to check for palindrome. Then the number which is entered by user is stored inside num which is copied into temp variable. Then with the help of this while loop, I am calculating number of digits which are available in the number and the result will be available inside length variable. After completion of this loop, reverse function is called, this is known as function calling statement. Here num and length variables are passed inside reverse function and the result will be returned back into this result variable. Then using this if else block, I have checked whether the original number which is available inside num is equals to result or not. If it is equal, then number is palindrome will print. If it is unequal, then number is not palindrome will print. So this is definition of main. Now reverse function is defined. It is receiving this num argument into num, then length argument into length. Then a base condition is available, which is checking if length is one, then it will return num variables value. Otherwise it is returning a calculation that is num modulus 10 multiplied by POW 10 comma line minus one. So this calculation result will be stored inside the stack and next recursive calling will take place. That is reverse num by 10 comma minus minus length. So here reverse function is called inside its definition. So this is a recursion process to terminate recursion. I have implemented a base condition with the help of this if statement. So friends, the outcome of this recursion process will be result will be returned into this result variable and that will be checked by this if or else statement. Now I'm going to execute this code. First time entering 121. You can see it is showing number is palindrome. It means 121. It's reverse is also 121. So it is a palindrome number. I am again executing this code. This time I am entering 123. You can see it is showing number is not palindrome because it's reverse is 321, which is not equals to 123. So friends, I hope with the help of this demonstration, you have understood how you can calculate reverse of a number and how you can use that reverse for checking whether the number is palindrome or not. If you want to watch more programming related videos, you can subscribe my YouTube channel. Follow my YouTube channel. Thank you for watching this video.