Created
November 15, 2011 16:33
-
-
Save cassiomarques/1367515 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
value1 = 10; | |
var value2 = 0; | |
if(value2 == '') { | |
console.log("Não deveria ter sido executado!"); | |
} | |
var funA = function() { | |
value1 = value1 * 2; | |
} | |
funA(); | |
console.log("O valor de 9 * 10 é " + 9 * value1); | |
var value3 = "bla" * 10; | |
if(value3 === NaN) { | |
console.log("Deveria ter sido executado..."); | |
} | |
// O método concat() dos tipos String e Array realizam a concatenação do objeto com o | |
// atributo recebido | |
var value4 = "blabla"; | |
value4.concat(" bleble"); | |
if(value4 === "blabla bleble") { | |
console.log("Deveria ter sido executado..."); | |
} | |
var value5 = [1,2,3]; | |
value5.concat([4,5]); | |
if(value5.length == 5) { | |
console.log("Deveria ter sido executado..."); | |
} | |
var obj = {abc: 10, def: 20}; | |
var value6 = obj.ghi; | |
if(value6 === null) { | |
console.log("Deveria ter sido executado..."); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment