OK, so I'm trying to improve my JS and I've come across the popular Palindrome checker exercise. This time, this solution from freeCodeCamp is supposed to perform very well, but I cannot understand several aspects of it.

```
/this solution performs at minimum 7x better, at maximum infinitely better.
    //read the explanation for the reason why. I just failed this in an interview.
    function palindrome(str) {
      //assign a front and a back pointer
      let front = 0
      let back = str.length - 1

      //back and front pointers won't always meet in the middle, so use (back > front)
      while (back > front) {
        //increments front pointer if current character doesn't meet criteria
        if ( str[front].match(/[\W_]/) ) {
          front++
          continue
        }
        //decrements back pointer if current character doesn't meet criteria
        if ( str[back].match(/[\W_]/) ) {
          back--
          continue
        }
        //finally does the comparison on the current character
        if ( str[front].toLowerCase() !== str[back].toLowerCase() ) return false
        front++
        back--
      }

      //if the whole string has been compared without returning false, it's a palindrome!
      return true

    }

```

Now, I have several questions regarding this code:

1- What is the point of reducing the length of str by 1? I've seen this in several Palindrome checkers and I still cannot wrap my head around it.

2- does the .match method means "return true if the argument contains these characters"?

3- how come "/[\W\_]/" equals "all characters"?

4- what is the point in adding 1 and subtracting 1 to front and back? Especially at the end of the function.

Thank you and sorry if it's a silly question, I'm just really interested in comprehending the logic here.