Q:

how to sscanf this string

how can I sscanf the following string
empty(1)
empty(20)
I tried the following but always failed
int count;
sscanf(buf, "%*s(%d)", &count)

Thanks in advance!

A:

change to 
sscanf(buf, "%*[^(](%d", &count);

