Vidyalelo
JavaScript · Q15

Array And Function

Programming · JavaScript · question 15

Q15

What will happen if a return statement does not have an associated expression?

A.
It returns the value 0
B.
It will throw an exception
C.
It returns the undefined value
Answer
D.
None of the mentioned

Answer: Option C

Solution

Answer: Option C
Solution:
If the return statement does not have an associated expression, it returns the undefined value.