User Tools

Site Tools


Programming Reference/Librarys

Question & Answer

Q&A is closed

to support this page (eg 0,42 € or so) Thanks.


int cscanf(char *format[, address, ...]); 

description of cscanf

reads input from the console and reformat it.

cscanf reads directly from the console of a series of input fields one character at.
Then each field is formatted according to the format specifier is passed cscanf in the format designated by the pointer format string.
Finally stores cscanf formatted input to the direction indicated by the argument address memory address and shows the input on the screen.
There must be as many format specifiers and addresses given as input fields.

#include <conio.h>
int main(void)
    char string[80];
    cprintf("Enter a string :");
    cscanf("%s", string);
    cprintf("\r\nyour string: %s", string);
    return 0;

output of cscanf c example

  Enter a string : 42theanswerismypadavan
  your string: 42theanswerismypadavan
c/conio.h/cscanf.txt · Last modified: 2013/02/03 21:15 by