In this JavaScript Walkthrough from Learn JavaScript, Functions, Return Statement Explained, on Codecademy, we learn that functions by default return undefined. If we want it to return a value, then it is important that we give our function a return statement. A return statement allows us to return a value from our function. If we create a function without a return value and call the function in a console.log(), then undefined would be logged out. If we give our function a return value, then calling the function in a console.log would log out the return value. Understanding Return Statements in JavaScript is key in developing into a great developer. Make sure to understand how return statements work in JavaScript before moving on. It is helpful in JavaScript, and in many other languages!
En esta página del sitio puede ver el video en línea Learn JavaScript, Functions, Return Statement Explained, Codecademy Learn Programming with JS ES6 de Duración hora minuto segunda en buena calidad , que subió el usuario We Will Code 23 febrero 2022, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 726 veces y le gustó 11 a los espectadores. Disfruta viendo!