I declare an array that can hold 10 parameters:
int a[10] = {2,3};
But I actually have 2 parameters, when I use sizeof() :
int n = sizeof(a) / sizeof(int);
It showed the length of the array is 10, but I want the result is: 2 as I only got 2 parameters. How can I do that ? Thx.