Is Palindrome

STRING

Problem

Given a string s, return true if it is a palindrome, and false otherwise.

A palindrome is a string that reads the same backward as forward.

Examples:

isPalindrome("racecar") // true // The string "racecar" reads the same backward as forward. isPalindrome("hello") // false // The string "hello" does not read the same backward as forward. isPalindrome("radar") // true // The string "radar" reads the same backward as forward.
Loading...