i need to discover the usage of" node ptr "-vs- "node *ptr"
well.... can you find out the problem is ? describe more about the different? i'm still dont know the how to write the syntax and even dont know what's the usage of the 2 options.
how about "typedef" usage?
Code:
--------------------------------------------------------
void test(getnode *ptr);
#include <stdio.h>
typedef struct {
int a;
int b;
} NODE;
int main ()
{
NODE getnode;
NODE *ptr;
printf ("Please enter your num > ");
scanf ("%d",&getnode.a);
printf ("Please enter your 2nd num > ");
scanf ("%d",&ptr->b);
printf ("your ans is ... %d and %d\n\n", getnode.a, ptr->b);
return 0;
}
Code Tags added by Hammer