arrays Various ways of accessing arrays Iterating an Array using recursion in C


Example

int sumArrayRecursive(int * arr, int index, int arraySize)
{
    if (index == (arraySize - 1))
    {
        return arr[index];
    }
    return arr[index] + sumArrayRecursive(arr, index + 1, arraySize);
}