JavaScript Algorithms and Data Structures Projects - Palindrome Checker

Just starting to code this project when I realize what appears to be an error in the requirements. I checked the forum boards but cannot find anything.

One of the tests is:
palindrome("0_0 (: /-\ :) 0-0") should return true
However, this is actually false. There is an underscore “_” between the first 0’s and a hyphen “-” between the second 0’s.

Does JavaScript recognize these as the same character? Seeing as others are passing this test and no one has brought this up, am I missing something? My initial code returns false for this test … which is actually correct, but they are looking for true.


No, but it does not matter. If you remove all the non-alphanumeric characters (anything that is not a letter or number), palindrome("0_0 (: /-\ :) 0-0") should return true.

All non-alphanumeric characters removed:


This is a palindrome.

Please post a link to the challenge

You missed this part of the instructions:

Note: You’ll need to remove all non-alphanumeric characters (punctuation, spaces and symbols) and turn everything into the same case (lower or upper case) in order to check for palindromes.

Ahhh … got it. Hadn’t started removing those characters yet. Just some initial coding for tests.

thank you!