.. | ||
solution | ||
README.md | ||
reverseString.js | ||
reverseString.spec.js |
Exercise 03 - Reverse a String
Pretty simple, write a function called reverseString
that returns its input, reversed!
reverseString('hello there') // returns 'ereht olleh'
Hints
Strings in JavaScript cannot be reversed directly so you're going to have to split it into something else first.. do the reversal and then join it back together into a string.