Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
why am I incorrectly referencing a pointer in a struct?zmienna_strukt.a=NULL; ... scanf("%s", wsk->a);
struct morgan zmienna_strukt;
struct morgan *wsk;
unsigned char buf[100];
wsk=&zmienna_strukt;
printf("Впиши значение: ");
fflush(stdout);
scanf("%d", &zmienna_strukt.b);
printf("%d \n\n", zmienna_strukt.b);
zmienna_strukt.a=buf;
buf[0] = 0;
printf("%s \n\n", zmienna_strukt.a);
printf("Впиши значение: ");
fflush(stdout);
scanf("%s", wsk->a);
printf("%s \n\n", wsk->a);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question