Because the insurance research machine test, so the C language looked, originally feel good, really found a few very basic to the problem will not.
1.
struct Node { int*pnode;
This defines the alias node for struct node, which I thought pnode was defined as a node type pair pointer ... Now I know I'm stupid.
It's actually supposed to define an alias for struct node * called Pnode.
2.
About character Arrays:
char s[] = {'a'b'c ' ' D '};
This defines a character array s and initializes it. But strlen (s) refers to 5 (GCC and vs run results may be different!). ), the value of sizeof (s) is 5;
But if you define this:
Char " ABCDE ";
Here the value of strlen (s) should be also 5, and the value of sizeof (s) is 6;
The result of sizeof is different because the compiler does not require the last to add a ' \ ', so when the group applies strlen to it, different compilers may have different results.
For the latter pair of definitions, the compiler requires that the end of the group be added a '/s '.
C Language Basics