I've got the following code:
My compiler gives me a warning that the variables a and b haven't been declared. I don't really understand what mistake I have made here. Is it with the structure in general, or did I commit a mistake in the syntax?Code:#include <stdio.h> struct first { int a; int b; }; int main() { struct first; scanf(" %d", &first.a); scanf(" %d", &first.b); getchar(); return 0; }
Thank You.