Answer:
I'm sure that code is JS,
so the problem is you are using the < > operator with a number and a string. This is a comparison operator and wouldn't work with any other type than number
3.5m questions
4.4m answers