How to use array of structures in C