DrFirst Interview Question

Basic Javascript sorting question , palindrome