Please help me understand this piece of code.
The first structure is easy, but the second one I can't understand at all.
What does it mean struct Address rows[MAX_ROWS]. Does it have any relaton to the first structure. And in the third structure as I understood is pointer to the second one. I'll appreciate you help.
1) struct isn't mandatory int this case. You can write Address rows[MAX_ROWS] and it will work. Notice how it is similar to int foo[BAR].
It is an array of MAX_ROWS entries of type Address.
Third structure has a pointer to Database type variable.
Example of use:
1 2 3
c.db = new Database;
(c.db->rows).id = 500;