判断字符串为6~12位“字符”
来源:互联网 发布:mac如何卸载flash插件 编辑:程序博客网 时间:2024/04/29 06:45
- (BOOL)isValidateName:(NSString *)name{
NSUInteger character = 0;
for(int i=0; i< [name length];i++){
int a = [name characterAtIndex:i];
if( a > 0x4e00 && a < 0x9fff){ //判断是否为中文
character +=2;
}else{
character +=1;
}
}
if (character >=6 && character <=12) {
return YES;
}else{
return NO;
}
}
1 0
- 判断字符串为6~12位“字符”
- 通过位操作判断字符串中是否存在重复字符
- Java判断十一位字符串是否为纯数字
- iOS 判断字符串是否为空字符串 && 判断字符串包含那个字符
- delphi 判断字符串中某个字符为中文
- 判断字符串最后一个字符是否为.号
- OC 中判断字符串是否为空字符
- 字符串旋转及判断是否为旋转后的字符
- 判断字符串或者单个字符是否为字母
- C判断字符输入是否为指定字符串
- 判断字符为数字
- iOS判断输入框的字符为8-15位纯数字或者英文
- 判断字符串为空
- 判断字符串为空
- 判断是否为字符串
- 判断字符串为空
- 判断字符串为空
- 判断 字符串 为空
- xListView
- HttpUrlconnection+pull
- iOS UIAlertController
- Xcode创建Swift和OC的桥接文件
- Python CGI编程
- 判断字符串为6~12位“字符”
- pull+httpurl
- vim中tab 字符配置
- C++之IO流
- 阿里云企业级互联网架构
- HttpUrlConnection和Pull解析
- Linux下的文件查找命令——find
- 畅通工程 problem c
- python操作mysql数据库