Skip to content

Instantly share code, notes, and snippets.

@larzconwell
Created July 30, 2012 19:39
Show Gist options
  • Save larzconwell/3209490 to your computer and use it in GitHub Desktop.
Save larzconwell/3209490 to your computer and use it in GitHub Desktop.
var reverse = function(array) {
var i = array.length
, arr = [];
while(--i >= 0) {
arr.push(array[i])
}
return arr;
}
reverse(['c', 'b', 'a']) == ['a', 'b', 'c']
=> false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment