You need to allocate (and eventually free) memory for each pointer in "array" before assigning a string to it. And in 'C', you cannot copy strings with the assignment operator. You need to use...