I don't know much about callbacks. How does the second 1 come from the beginning, and the parameters after 3. I drew a picture, but I still can't imagine how it works.
The first number, the second value is 1, this is a rule of.
Starting from the third number, the value of the current number is the sum of the previous two numbers. This is the inherent law of the Fibonacci sequence.
Use recursive thinking to find the value of the nth number: fibonacci($n) = fibonacci($n-1)+fibonacci($n-2);
This is called recursion, not callback
Fibonacci sequence: 1, 1, 2, 3, 5, 8, 13....
The first number, the second value is 1, this is a rule of.
Starting from the third number, the value of the current number is the sum of the previous two numbers. This is the inherent law of the Fibonacci sequence.
Use recursive thinking to find the value of the nth number: fibonacci($n) = fibonacci($n-1)+fibonacci($n-2);
The picture is based on my understanding, I hope it can help you understand better what my problem is