Created
March 4, 2020 19:15
-
-
Save jouderianjr/86d4fedd253da39d30a069b9f0245113 to your computer and use it in GitHub Desktop.
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
console.log("Hello victor"); | |
// Creating a variable and setting a string to it; | |
var person = "Victor"; | |
console.log(person); | |
// Changing the value of the variable | |
person = "Jouderian"; | |
console.log(person); | |
// number; | |
var age = 18; | |
age = age * 2; | |
console.log(18 + 2); | |
console.log(person + " " + age); | |
var result = "you can drink"; | |
if (age < 18) { | |
result = "underage"; | |
} else if(age == 18) { | |
result = "Exactly age"; | |
} else { | |
result = "you can drink"; | |
} | |
console.log(result); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment