Home / CSE MCQs / Javascript MCQs :: Discussion

Discussion :: Javascript MCQs

  1. What will happen if a return statement does not have an associated expression?
  2. A.
    It returns the value 0
    B.
    It will throw an exception
    C.
    It returns the undefined value
    D.
    None of the mentioned

    View Answer

    Workspace

    Answer : Option C

    Explanation :

    If the return statement does not have an associated expression, it returns the undefined value.


Be The First To Comment