.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month

Home >> Code Snippets >> Visual Studio >> Post New Resource Bookmark and Share   

 Subscribe to Code Snippets

Find The Number Is Palindrome Or Not...

Posted By:Ghanashyam Nayak       Posted Date: December 04, 2010    Points: 15    Category: Visual Studio    URL: http://www.dotnetspark.com  

Code for find the given user number is palindrome or not...

Sub Main()
	Dim n, temp As Long
	Console.Write("Enter the mumber : ")
	n = Console.ReadLine()
	While (n > 0)
		i = n Mod 10
		n /= 10
		rev = (rev * 10) + i
	End While
	If (rev = temp) Then
		Console.WriteLine(temp & " is PALINDROM.")
		Console.WriteLine(temp & " is not PALINDROM.")
	End If
End Sub


Further Readings:


No response found. Be the first to respond this post

Post Comment

You must Sign In To post reply
Find More code samples in C#, ASP.Net, Vb.Net and more Here

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend