Strings In Depth2 / 18
Up next

Array of strings

#include <stdio.h>

int main(void) {
    const char *words[] = {"one", "two", "three"};
    size_t n = sizeof words / sizeof words[0];
    for (size_t i = 0; i < n; i++) {
        printf("%s\n", words[i]);
    }
    return 0;
}
What you're solving

an array of char pointers