Created
November 10, 2014 06:42
-
-
Save stoeffel/375081483e66272785db to your computer and use it in GitHub Desktop.
// source http://jsbin.com/kalezo
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>JS Bin</title> | |
</head> | |
<body> | |
<script id="jsbin-javascript"> | |
function one() { | |
var hasCake = true; | |
two(); | |
function two() { | |
if (hasCake) { | |
console.log("Yummie"); | |
} else { | |
console.log("The cake is a lie."); | |
} | |
if (1 === 1) { | |
var hasCake = true; | |
if (hasCake) { | |
console.log("mmh.."); | |
} else { | |
console.log("No cake for you."); | |
} | |
} | |
} | |
} | |
one(); | |
</script> | |
<script id="jsbin-source-javascript" type="text/javascript">function one() { | |
var hasCake = true; | |
two(); | |
function two() { | |
if (hasCake) { | |
console.log("Yummie"); | |
} else { | |
console.log("The cake is a lie."); | |
} | |
if (1 === 1) { | |
var hasCake = true; | |
if (hasCake) { | |
console.log("mmh.."); | |
} else { | |
console.log("No cake for you."); | |
} | |
} | |
} | |
} | |
one(); | |
</script></body> | |
</html> |
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
function one() { | |
var hasCake = true; | |
two(); | |
function two() { | |
if (hasCake) { | |
console.log("Yummie"); | |
} else { | |
console.log("The cake is a lie."); | |
} | |
if (1 === 1) { | |
var hasCake = true; | |
if (hasCake) { | |
console.log("mmh.."); | |
} else { | |
console.log("No cake for you."); | |
} | |
} | |
} | |
} | |
one(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment