How would I initialize certain fields in a struct in a class constructor?
I want to create a 11x11 vector.
Say I have the struct:
Here is where it is declared as a 2d array:
int x, y;
Here is what I attempted to do to initialize two things:
vector<vector<tree_node*> > board_values
and I got stuck on how to initialize it. Would I have to manually malloc/new, set the fields to zero manually for each, then push it on the vector 121 times?
board_values(10, vector<tree_node*>(11, tree_node->x // and tree_node->y