Function to check if a word is palindrome
function checkPalin ( word ) { var n = word . length word = word . toLowerCase ( ) ; for ( var i = 0 ; i < n ; i ++ , n -- ) if ( word [ i ] != word [ n - 1 ] ) return false ; return true ; }