+ 1

How to make palindrome words checker in JavaScript?

9th Apr 2020, 8:36 PM
Hamza Yousuf
Hamza Yousuf - avatar
2 Respostas
+ 1
Thanks bro
10th Apr 2020, 6:51 PM
Hamza Yousuf
Hamza Yousuf - avatar
0
// with the help of ES6: var no = 'palindrome', yes = 'racecar'; const is_palindrome = s => [...s].reverse().join('') == s; console.log(is_palindrome(no)); console.log(is_palindrome(yes)); /* sentences needs a few more steps to handle words separators ;) */
9th Apr 2020, 9:30 PM
visph
visph - avatar