typedef struct {
char name[][MAX1];
char state[][MAX1];
char id[]MAX1];
} Station;
These are not considered 2D arrays. They are incorrect. You can use 2D arrays, you just have to specify the size:
Code:
struct mystruct {
char array[3][45];
};
There is no point in having your 2D array as you have described it. Remember this:
You can only use empty [] for an array argument when you are providing the data for it at that time:
Code:
struct somestruct mytable[] = {
{ "hello", 20, 4.33 },
{ "whee", 453, 1.302 },
{ "goodbye", 3, 0.12 },
{ "", 0, 0.0 }
};
Quzah.