Can we add condition into "else"

Hi,
I was doing a project. The tutorial video’s answer for one step is like following:

  if (choreDoor===0){

  }else if(choreDoor===1){

  }else{ (choreDoor===2)

  }

I saw the instructor put a condition (choreDoor===2) into the last “else”. I am not sure if it is correct to code like this. Anyone can help me? Thanks

doing the following:

else (choreDoor === 2) {

}

would give an error. Given we can’t use a condition for else

on the other hand:

else{
   (choreDoor===2)
}

where the condition is within the clause/body of else is allowed, however, the condition is not doing anything and is totally redundant.

its important to understand the difference.

If it is not doing anything, why the instructor put it here? Is it just for readability? Is it better to delete it or leave it?

You would have to ask the instructor. Could be a mistake. We all make mistakes, or rush things though because of deadlines. There are so many possibilities and variables.

I would delete it, it looks like dead wood. But even better: what do you think? Why remove it? Or why not? You don’t have to answer these questions to me, just answer them for yourself. Doing this kind of analyzes is very important

Thank you for your answer.