problem with input

Aug 13, 2012 at 2:32pm
printf("%d",scanf("%c%c",&a,&b));
why it is not taking two inputs???
Aug 13, 2012 at 3:43pm
man wrote:
c
Matches a sequence of characters whose length is specified by the maximum field width (default 1); the next pointer must be a pointer to char, and there must be enough room for all the characters (no terminating null byte is added).
The usual skip of leading white space is suppressed. To skip white space first, use an explicit space in the format.


Edit: It is taking two input, as printf() should be telling you.
Last edited on Aug 13, 2012 at 3:45pm
Topic archived. No new replies allowed.