Created
September 13, 2014 10:50
-
-
Save fritzvd/25cda0ec362e669fefca to your computer and use it in GitHub Desktop.
Performance in javascript
This file contains hidden or 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
// this is wrong | |
var multiList = []; | |
multiList += 'string'; | |
multiList += 9; | |
multiList += 3.14; | |
// if you really want a list like this do this: | |
var multiList = ['string', 9 , 3.14]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment