-
-
Save devotdev/095137596c87807b6721eaba62a886be to your computer and use it in GitHub Desktop.
Function that returns a value
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
| function add(a, b) { | |
| return a + b; | |
| } | |
| const result = add(5, 3); // The function returns 8, which is stored in 'result' | |
| console.log(result) // Output: 8 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment