Basic JavaScript - Return a Value from a Function with Return

Tell us what’s happening:
Describe your issue in detail here.
I Dont understand the concept
Your code so far


Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/110.0

Challenge: Basic JavaScript - Return a Value from a Function with Return

Link to the challenge:

HI @abbasshaikhji4 !

It might help to break down the example they gave you.

function plusThree(num) {
  return num + 3;
}

We have a function called plusThree that has a parameter called num.

Inside that function we are returning the result of adding the parameter of num with the number 3.

When we call the function like this plusThree(5) it will execute the expression of 5+3 and return 8.

The challenge is similar to the example they gave you.
But this time you will multiple the parameter by 5 and return it.

Hope that helps!

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.