Palindrome Check
JAVASCRIPT
Medium
+20 XP
Problem Description
Write a function `isPalindrome(str)` that returns `true` if the string reads the same forwards and backwards (ignore case), `false` otherwise.
Example:
isPalindrome('racecar') → true
isPalindrome('hello') → false
isPalindrome('Madam') → true
Example:
isPalindrome('racecar') → true
isPalindrome('hello') → false
isPalindrome('Madam') → true
Test Cases
Input: isPalindrome('racecar')
Expected: 1
Input: isPalindrome('hello')
Expected:
Input: isPalindrome('Madam')
Expected: 1
Input: isPalindrome('level')
Expected: 1
Your Solution