using System;
namespace NumbersReverse
{
class Program
{
static void Main(string[] args)
{
int num, reverse = 0;
Console.WriteLine("Enter the number ");
num = int.Parse(Console.ReadLine());
while(num != 0)
{
reverse = reverse * 10;
reverse = reverse + num % 10;
num = num / 10;
}
Console.WriteLine("reverse numbers :" + reverse);
Console.ReadLine();
}
}
}
Post a Comment
If you have any doubt please let me know