Need an explanation of Recursion

I try to understand how it works on Recursion lesson and I try to use the code on VS code but I don’t understand why the result is NaN. Can somebody help me to explain more about recursion?

function multiply(arr, n) {
  if (n <= 0) {
    return 1;
  } else {
    return multiply(arr, n - 1) * arr[n - 1];
  }
}

var re = multiply(1,10);
console.log(re);

first argument a number, second argument a number

first parameter is an array and used as such

so, arr[n - 1] is not a number, and the multiplication results in NaN (Not a Number)

Check this video Look Closer. Another video on how to execute code line by line.

Thank you for your explanation. I have more understanding now.

Thank you for the video.