The array sizeof thing only works when the definition of the array is in scope - that is, the compiler can see the actual array.
An array declaration, say
extern int array[ ];
or an array parameter
void foo ( int array[ ] );
needs a different approach.
Reputation Points: 5862
Solved Threads: 950
Posting Sage
Offline 7,164 posts
since Dec 2005