Linear search using recursion

https://ide.codingblocks.com/s/58847
why is it giving -1 ?
i cant figure out the erroe

@Shraddha2104 don’t call like that return linearsearch(arguments);
it’s a recursion it call automatically no need to add return and second thing is that you should add condition in your code like that
1 base case is that when your element in the array hits search element
if(a[i]==target){
return i;
}
2 thing is that you have to add one more thing when array is complete it traversal and arr[i]!=target you should return -1;
you can see this