scanf is dangerous.
Your program can be overflowed and this way you can arrange, without even knowing, a really big mess.
As Aia said, use fgets.
fgets works this way.
Code:
fgets(var, maximumNum, stdin); // This is an example how to get the user's input;
e.g:
Code:
char name[10];
printf("Enter your name please:\n");
fgets(name, 10, stdin);
printf("%s", name); // or fputs(name, stdout); or many other ways, lol
EDIT: Ahh! fgets & fputs works only for strings.
and just for the record, gets is also dangerous.