bool CheckPalindrome (string CheckString)
{
if (CheckString == null || CheckString.Length == 0)
{
return false;
}
for (int i = 0; i < CheckString.Length / 2; i++)
{
if (CheckString[i] != CheckString[CheckString.Length - 1 - i])
{
return false;
}
}
return true;
}
bool CheckPalindrome (string CheckString)
{
if (CheckString == null || CheckString.Length == 0)
{
return false;
}
for (int i = 0; i < CheckString.Length / 2; i++)
{
if (CheckString[i] != CheckString[CheckString.Length - 1 - i])
{
return false;
}
}
return true;
}
|