揮発性のメモ2

http://d.hatena.ne.jp/iww/

scanf

#include <stdio.h>

int main(void) {
    char *text = "123,456\n";

    int  no;
    char buf[]="bbbbbbbbbbbbbbb";

    sscanf(text,"%d,%s", &no, buf);
    printf("'%d','%s'\n", no, buf); // '123','456'

    return 0;
}