rangeOfString如果不够用的话,可以查询一下range开头的函数NSString* str = @"1232343453453";NSRange range = [str rangeOfString:@"a"];if (range.length > 0){}