 <p>Pointers do not keep information whether they point to single objects or for example first elements of arrays.</p> <p>Consider the following code snippet</p> <pre><code>char *p; char c = 'A'; p = &amp;c; putchar( *p ); char s[] = "ABC"; p = s; putchar( *p ); </code></pre> <p>Thus you have to provide yourself the information about whether a pointer points to an element of an array.</p> <p>You can do this in two ways. The first one is to specify the number of elements in the sequence the first element of which is pointed to by the pointer. Or the sequence must to have a sentinel value as strings have.</p> <p>For example</p> <pre><code>int a[] = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 0 }; for ( int *p = a; p &lt; a + sizeof( a ) / sizeof( *a ); ++p ) ^^^^^^^^^^^^^^^^^^^^^^^^^^ { printf( "%d ", *p ); } printf( "\n" ); </code></pre> <p>Or</p> <pre><code>int a[] = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 0 }; int *p = a; do { printf( "%d ", *p ); } while ( *p++ != 0 ); ^^^^^^^^^ printf( "\n" ); </code></pre> <p>These code snippets can be written as functions</p> <pre><code>void f( int a[], size_t n ) { for ( int *p = a; p &lt; a + n; ++p ) { printf( "%d ", *p ); } printf( "\n" ); } </code></pre> <p>Or</p> <pre><code>void f( int a[] ) { int *p = a; do { printf( "%d ", *p ); } while ( *p++ != 0 ); printf( "\n" ); } </code></pre> <p>The same way an array of strings can be printed. Either you will report explicitly the number of elements in the array yourself. Or you can use a sentinel value as for example a null pointer or an empty string.</p> <p>For example</p> <pre><code>#include &lt;stdio.h&gt; void PrintStringArray( char *s[], size_t n ) { for ( char **p = s; p &lt; s + n; ++p ) { puts( *p ); } printf( "\n" ); } int main( void ) ^^^^^^^^^^^^^^^^ { char *list[] = { "Green", "Yellow", "Black", "White", "Purple", "Saphire" }; PrintStringArray( list, sizeof( list ) / sizeof( *list ) ); return 0; } </code></pre> <p>Or</p> <pre><code>#include &lt;stdio.h&gt; void PrintStringArray( char *s[] ) { char **p = s; while ( *p != NULL ) { puts( *p++ ); } printf( "\n" ); } int main( void ) ^^^^^^^^^^^^^^^^ { char *list[] = { "Green", "Yellow", "Black", "White", "Purple", "Saphire", NULL ^^^^ }; PrintStringArray( list ); return 0; } </code></pre>