void fib(int **arr, int n)
{
    if (n == 1)
    {
        *arr[0] = 0;
    }
    else if (n == 2)
    {
        *arr[0] = 0;
        *arr[1] = 1;
    }
    else
    {
        *arr[0] = 0;
        *arr[1] = 1;
        for (int i = 0; i < n - 2; i++)
        {
            *arr[i + 2] = *arr[i - 2] + *arr[i - 1];
        }
    }
}
Define a function void fib(...) below. This function takes parameter n and generates the first n values in the Fibonacci sequence. The values should be stored in a dynamically-allocated array composed of exactly the correct number of integers. The values should be returned through a pointer parameter passed in as the first argument.