I have this program due on monday and i need to know how to dynmically create an array. Also i need to know how to determine the size of the dynamic array for my "while" loop

The program reads from a space delimited text file and is suppose to count the occurrences of words in the file.

Any suggestions?