Added isPalindrome() for p4
Removed debugging statement in P4
Added somewhat cheating P4