[Solved] completing this code (c) if you can


Change this:

Nodes_maker(count2,&currentnode);

to this:

Nodes_maker(count2, currentnode);

and the error will go away. That is because the prototype of the function is Nodes_maker(int nums,Node *currentnode) and you have Node* currentnode;.

However, you need to work on your logic. I mean you dynamically allocate memory, but you don’t return the pointer (your function returns void). Good luck!


PS: Do I cast the result of malloc? No.

4

solved completing this code (c) if you can