This question already has an answer here:
- Length of array in function argument 7 answers
How can I calculate the number of elements in the array if I don't want to pass the number of elements as another argument say,
fun(a, sizeof(a)/sizeof(*a));
and receive as
int fun(int a[], int limit)
{
}
Aucun commentaire:
Enregistrer un commentaire