So I am already passed the recursion tutorials in the curriculum but I can’t seem to figure it out without googling for help. I understand the very basics but some things trip me up and I can’t wrap my head around yet.
Like in the challenge where you use recursion to make an array: Why do they set a variable as the function?
let arr = makeRangeOfNumbers(startNum, endNum - 1);
I can’t figure out how giving a variable a recursive function is able to push numbers into it when arr isn’t an array yet? I was setting arr as [ ] first but that got me nowhere.
Anyways I’m lost.