Answer Posted / kautilya
bool CheckPalindrom(string MyString)
{
string strChar1 = "";
string strChar2 = "";
for (int i = 0; i < ((MyString.Length - 1) / 2);
i++)
{
strChar1 = MyString.Substring(i, 1);
strChar2 = MyString.Substring((MyString.Length -
(i+1)), 1);
if (strChar1 != strChar2)
return false;
}
return true;
}
| Is This Answer Correct ? | 11 Yes | 7 No |
Post New Answer View All Answers
What is class sortedlist underneath?
What is the correct way of declaring an xml namespace?
What is ulong in c#?
Why do we use Design Pattern in C#?
What are scriptable objects?
What are the fundamental principles of oo programming?
Does c# support a variable number of arguments?
For methods inside the interface why can’t you specify the accessibility modifier?
What is IL / CIL / MSIL?
what is inheritance and an example in vb.net and c# of when you might use it?
Can you explain template pattern?
What is private variable?
What is the use of flag in c#?
What are the 3 different types of arrays?
What is cookies in c# asp net?