Last active
January 28, 2021 07:06
-
-
Save ruan4261/c60deccea88c560fe61a8e9a835f4007 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* better | |
*/ | |
function(a, b) { | |
a = a ^ b | |
b = a ^ b | |
a = a ^ b | |
} | |
/** | |
* standard | |
*/ | |
function(a, b) { | |
var temp = a | |
a = b | |
b = temp | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment