C++ structures | Sololearn: Learn to code for FREE!

+1

C++ structures

What is the difference between: struct Node { int data; struct Node* next; }; struct Node* head; and: struct Node { int data; Node* next; }; Node* head;

3/23/2019 10:11:56 AM

coding-space.ru

1 Answer

New Answer

+2

coding-space.ru In C++ there is no difference , most of the time it is unnecessary qualification, nevertheless it is useful for declaring forward references. In C you need to use typedef for c++ style declaration, else use fully qualified names.