Hi.
I'm learning ANSI C for a few days now. I use Microsoft C 7.0 as a compiler, my target platform is DOS.
I'm having trouble grasping the idea of the asterisk in the scanf() function..
Why can't:
scanf("%i %*i %i",&value1,&value2,&value3);
be written as:
scanf("%i %i",&value1,&value2);
these two commands basically yield the same result, right?
then why bother with the asterisk to begin with?
thanks.
I'm learning ANSI C for a few days now. I use Microsoft C 7.0 as a compiler, my target platform is DOS.
I'm having trouble grasping the idea of the asterisk in the scanf() function..
Why can't:
scanf("%i %*i %i",&value1,&value2,&value3);
be written as:
scanf("%i %i",&value1,&value2);
these two commands basically yield the same result, right?
then why bother with the asterisk to begin with?
thanks.