Hi! I am new to the C programming language and have only programmed in C++ and Java before.
And I don't really know how to fix this error that probably is really simple to fix. The problem is that when I input my name and age the program will only print the age and not my name.
Code:#include <stdio.h> int main() { char name[] = ""; printf("State your name: "); scanf("%s", name); short age = 0; printf("Age: "); scanf("%d", &age); printf("Hello %s you are %d years old", name, age); return 0; }