I have problems with the recursive fibonacci function, in the exercise you are asked to print inside the function or even using an auxiliary recursive function, but it can not print in the main function, I tried everything for printing, however they keep repeating themselves, the recursive fibonacci function I know how to do, it just lacks the impression, it follows the enunciando and I ask someone to give me a light.
"The Fibonacci Sequence is defined by:
- F0 = 0
- F1 = 1
- Fn = F n - 1 + F n - 2 , for n> 1
Develop a recursive function that calculates and prints the first n numbers of the Fibonacci Sequence. The function should have the following signature:
int fibonacci (int n);
The function should print the first n numbers separated by spaces, for For example, for n = 10:
0 1 1 2 3 5 8 13 21 34 "