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
Name any three ways to pass parameters to a method in c#?
What is generic and non generic collections in c#?
Define a jagged array in c#?
What are mutable and immutable types in c#?
What is the difference between // comments, /* */ comments and /// comments?
What is cls, cts and clr in net?
What is uint16?
What is a di class?
What is generic delegates in c#?
What are the return types in c#?
Why delegates are required?
What is the purpose of ienumerable in c#?
What is difference between abstraction and encapsulation in c#?
How to do and Apply Themes to Datagrid,Lable,Textbox,etc., in C#.NET 2005 Windows Application? (like who we will do themes in ASP.NET using .CSS and .SKIN files). Urgent!!
What is the reason behind the invention of c#?