I know how to detect size of array after I created it by the help of sizeof paramater:
int arr[10];
printf("%i",sizeof(arr)/sizeof(int));
But as I understand, when I pass an array as a parameter to a function, Im acctually passing a pointer to the first element of the array, and not the actual array. So if I will use the sizeof operator I will get the size of the pointer.
I know I can find a size of a string(char array) by searching for '\0'. So lets assume we are talking about int array;
How can I detect the size of an array passed as argument?