[c-prog] need help on sscanf()

2007-12-12 Thread mano M
i need to use %s and %d in sscanf function. It is not actually working as I expected .I simulated the issue using a sample program. #includestdio.h int main() { char str[100]=hello|67; char s1[10]; int num; sscanf(str,%s|%d,s1,num); printf(%s,s1); } output: hello|67 I need to

Re: [c-prog] need help on sscanf()

2007-12-12 Thread Brett McCoy
On Dec 12, 2007 8:54 PM, mano M [EMAIL PROTECTED] wrote: i need to use %s and %d in sscanf function. It is not actually working as I expected .I simulated the issue using a sample program. #includestdio.h int main() { char str[100]=hello|67; char s1[10]; int num;