Learn Javascript, 2017, return II, Codecademy (Return Statements)

Channel:
Subscribers:
8,020
Published on ● Video Link: https://www.youtube.com/watch?v=1uf0O1HSunU



Duration: 5:37
735 views
5


In this lesson we look further into javascript return statements. A return statement returns a value and can be called from another function. In this lesson we add to our pizza order application by adding a tax function that calculates sales tax. Its important to note the difference between a console.log and a return statement. In javascript a console.log simply outputs computed data on the screen while a return statement is used to usually end a function call and return where it was called from with an optional result.







Tags:
javascript functions
functions in javascript
codecademy functions
javascript return statements