node *next_cell = NULL;
node *previous_cell = NULL;
That won't fly - in-class initializers for non-static members were only introduced in C++11.
About adj_list
, the real location of the error is here:
void print(node **dummy = adj_list, int i = 0, int k = 0);
// ^^^^^^^^^^
You can't have a class member as a default value because it's not known to which instance it should belong. You can't use this
there either, so you'll have to figure out some other way to pass a default value.