Sorting an Array Alphabetically with sort

I would suspect that the way you’ve done it will, going foward, break in all browsers, so have a check on the current solution here:

https://github.com/freeCodeCamp/freeCodeCamp/blob/master/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/functional-programming/sort-an-array-alphabetically-using-the-sort-method.english.md

And have a search on the forums - this has come up a lot because of the hint code not working in Chrome (and the fact that the solution worked fine up until recently, so if you google around you’ll find a lot of people using this method to sort), here’s one of my earlier answers:

1 Like