```
bool isCharacter(char c){
return (c >64 && c<91) ||(c > 96 && c< 123)||(c>47 && c<58);
}
bool isPalindrome(string s) {
int i = 0, j= s.size()-1;
while(i<j){
if(!isCharacter(s[i]))
i++;
else if(!isCharacter(s[j]))
j--;
else if (tolower(s[i++])!=tolower(s[j--]))
return false;
}
return true;
}
```

I found this solution is easy to come up with.