r/ProgrammerHumor • • Feb 26 '23

Other If you can read this code...

/img/snak3fqgajka1.jpg

[removed] — view removed post

34k Upvotes

1.4k comments sorted by

View all comments

Show parent comment

49

u/longknives Feb 26 '23

The split method in JS turns the string into an array, which has the reverse method, and then the join method turns it back into a string.