An easy code to get reverse of given number in c Language

4/20/2013 01:16:00 pm Unknown 0 Comments


#include <stdio.h>
#include <conio.h>
int main()
{
          int num,mod,rem;
          printf("Enter the Number to Find it's Reverse\n");
          scanf("%d",&num);
          while(num!=0)
          {
                     mod=num%10;
                     rem=num/10;
                     printf("%d",mod);
                     num=rem;
          }
          getch();
}