Why all testcase are not passed in my code.Plz tell the error in my code
Sorted array Problem
Hey @Alfred
bool sortedarray(long int a[],int n){ //long here because u created long int array
if(n==1){
return true;
}
if(a[0]<=a[1] && sortedarray(a+1,n-1)){ //<= here
return true;
}
return false;
}
plzz help in this code