Please help me in this challenge

Tell us what’s happening:

Your code so far

// Example
var sum = 0;
function addThree() {
sum = sum + 3;

function addFive() {
sum += 5;

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.116 Safari/537.36.

Challenge: Understanding Undefined Value returned from a Function

Link to the challenge:

Hi there,

you did not called two functions,

function addThree();
function adFive();

The challenge tells to return the value of the function addFive(); so you can try to understand this.
You can have a variable assigned to the function addFive(); to validate.

Let me know if you understand it, or solved the problem :slight_smile:

Ya,thank u very much

you can have the function like this

function addFive(){
sum += 5; // with no return 


function addFive(){
sum += 5; 
// add a variable to return and validate undefined.
var valueReturned = addFive();
console.log(valueReturned); // output undefined.