Name: Anonymous 2009-05-24 9:14
what the fast way to check that string contain only characters within some set like "a-z0-9"?
int
is_inset
(
const char
* s )
{ while
( *s
) {
if ( !( ( *s
>= 'a'
&&
*s
<= 'z' )
|| ( *s
>=
'0'
&&
*s <=
'9' )))
return
0 ;
++s ; }
return 1
;
}