Last active
June 30, 2017 19:23
-
-
Save carcigenicate/9d7e7474690b80e4fd37bf62bcea13ff 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
// Create a function called "add" | |
function add(num1, num2) { | |
var result = num1 + num2 | |
return result // <----- Returning from the function | |
} | |
var result = add(1, 2) // <----- Called the function. "result" holds a 3 | |
var result2 = add(3, 4) // <----- Called the function again. "result2" holds a 7 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment