Doubt in function parameters

Hi, I am getting confused about how an array is being passed to the function in the context of recursion can you explain its working. I know the basic idea is to pass the address of the first element and pass the next address of the next element in the recursive call.

the recursive call was in the statement:
if(a[0]<a[1]&&issorted(a+1,n-1))

Say for any array a[10]
If you say simply ‘a’ - It means the base address of the array. So it will start from a[0]
a+1 means the next addres to the base address. So it will start from a[1]
In the above statement you have compared a[0 ] with a[1] so you now pass the new array with base address at a[1].

ohk so in the function definition int *a will act as a pointer to the base address?

@sahilsaini137 Yes…it will hold the base address

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.