+(BOOL)JudgeString:(NSString *)string{
NSString *regex =@"[A-Za-z]+";
NSPredicate*predicate = [NSPredicate predicateWithFormat:@"SELF MATCHES %@",regex];
return[predicate evaluateWithObject:string];
}
+(BOOL)JudgeString:(NSString *)string{
NSString *regex =@"[A-Za-z]+";
NSPredicate*predicate = [NSPredicate predicateWithFormat:@"SELF MATCHES %@",regex];
return[predicate evaluateWithObject:string];
}
本文标题:(IOS)判断字符串首字符是否为字母
本文链接:https://www.haomeiwen.com/subject/zrfklqtx.html
网友评论