Skip to content

Instantly share code, notes, and snippets.

@pleabargain
Created February 19, 2017 13:49
Show Gist options
  • Save pleabargain/92af5c066707138cb5626c0974c644ae to your computer and use it in GitHub Desktop.
Save pleabargain/92af5c066707138cb5626c0974c644ae to your computer and use it in GitHub Desktop.
return a string in js in reverse
function FirstReverse(str) {
return str.split("").reverse().join("");
}
FirstReverse("here is some text");
//output "txet emos si ereh"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment