scanf example required

From your experience, please cite an example where asterisk is used in
format specification of scanf() function to suppress an assignment.

Thank you.

One use would be where you are using the related function sscanf to parse a line of data and there is a field you want to skip. You want to make sure it’s there and of the right format so that you can locate the next field, but you don’t want its value or to have to assign it to a dummy variable. This is where the * suppression specifier would come in handy.

ken yap wrote:

>
> One use would be where you are using the related function sscanf to
> parse a line of data and there is a field you want to skip. You want to
> make sure it’s there and of the right format so that you can locate the
> next field, but you don’t want its value or to have to assign it to a
> dummy variable. This is where the * suppression specifier would come in
> handy.
>
>
Thanks Ken.