Skip to content

Instantly share code, notes, and snippets.

@devotdev

devotdev/add.js Secret

Last active December 18, 2024 09:16
Show Gist options
  • Select an option

  • Save devotdev/095137596c87807b6721eaba62a886be to your computer and use it in GitHub Desktop.

Select an option

Save devotdev/095137596c87807b6721eaba62a886be to your computer and use it in GitHub Desktop.
Function that returns a value
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