Skip to content

Instantly share code, notes, and snippets.

@tomoya55
Created September 22, 2012 04:58
Show Gist options
  • Save tomoya55/3765175 to your computer and use it in GitHub Desktop.
Save tomoya55/3765175 to your computer and use it in GitHub Desktop.
compare two arrays
function equalArrays(a, b) {
if (a.length !== b.length) return false;
for(var i = 0; i < a.length; i++)
if (a[i] !== b[i]) return false;
return true;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment