in other programming language like Pascal, we can refer the link list like:
top^.next^.data = 123;
top^.next^.next = nil;
but in C, i don't know what's the problem. i just know when i try to compile the following code, error message occurs:
top->next->data = 123;
top->next->next = NULL;
the structure type is defined is like this:
typedef struct {
int data;
struct List *next;
} List;
i have no any problem when i write these:
top->data = 123;
top->next = NULL;
thank you for you attention.
actually, i'm not a actual C/C++ programmer. i call myself as programmer here because i want to be a real programmer. and the programming language i mot like is C/C++. is these 2 languages can produce whatever things? no matter we want or not?
top^.next^.data = 123;
top^.next^.next = nil;
but in C, i don't know what's the problem. i just know when i try to compile the following code, error message occurs:
top->next->data = 123;
top->next->next = NULL;
the structure type is defined is like this:
typedef struct {
int data;
struct List *next;
} List;
i have no any problem when i write these:
top->data = 123;
top->next = NULL;
thank you for you attention.
actually, i'm not a actual C/C++ programmer. i call myself as programmer here because i want to be a real programmer. and the programming language i mot like is C/C++. is these 2 languages can produce whatever things? no matter we want or not?