write program in C# for palindrome? (aug 2009)
write program in C3 for generating below output?(aug 2009)
#
# #
# # #
# # # #
Answer Posted / elan
string sName = "elan";
char[] aName = sName.ToCharArray();
Array.Reverse(aName);
string sReversedName = new string(aName);
if (sName == sReversedName)
{
MessageBox.Show("it is palindrome");
}
else
{
MessageBox.Show("it is not palindrome");
}
| Is This Answer Correct ? | 25 Yes | 10 No |
Post New Answer View All Answers
What is serialization and deserialization in c# with example?
Explain the advantage of using system.text.stringbuilder over system.string?
What is a Managed Code??
How many bits is int32?
What is the difference between string and string in c#?
What is static classes?
What is difference between comparable and comparator?
Explain the various types of classes used in c#?
What is c# used for?
Explain the functionalities of satellite assembly?
Can you access a hidden base class method in the derived class?
Explain polymorphism in c# with a simple example?
Can you prevent a class from being instantiated?
What is the use of iqueryable in c#?
What is join in c#?