我听的最多的话就是“这个我就不说了”!我以前遇到的老师,还没见过一直把这句话挂在嘴边的!难得没人觉得讲得极其不完整吗?老师们的时间真是赶啊,一套视频一个多小时,这也不说那也不说,呵呵!
2015-12-08
最新回答 / 无谓艰苦
#import <Foundation/Foundation.h>#import "PeopleAll.h"int main(int argc, const char * argv[]) { @autoreleasepool { PeopleAll *people1 = [[PeopleAll alloc] init]; PeopleAll *people2 = [[PeopleAll alloc] init]; PeopleAll *peopl...
2015-12-03
//字符串指定范围替换
NSString *str14 = [str13 stringByReplacingCharactersInRange:NSMakeRange(0, 2) withString:@"dan"];
NSLog(@"str14 = %@" , str14);
NSString *str14 = [str13 stringByReplacingCharactersInRange:NSMakeRange(0, 2) withString:@"dan"];
NSLog(@"str14 = %@" , str14);
2015-11-07
判断字符串是否相同
[str isEqualToString]
比较字符串
NSComparisonResult
按指定字符分割字符串
[str componentsSeparatedByString]
按照范围截取字符串
NSMakeRange
1.从某一位开始
[str substringFromIndex]
2.从开头
[str substringToIndex]
拆分字符串
for
[str characterAtIndex]
查找指定字符串位置
[str rangeOfString]
替换
[str stringByReplacingCharactersInRange]
[str isEqualToString]
比较字符串
NSComparisonResult
按指定字符分割字符串
[str componentsSeparatedByString]
按照范围截取字符串
NSMakeRange
1.从某一位开始
[str substringFromIndex]
2.从开头
[str substringToIndex]
拆分字符串
for
[str characterAtIndex]
查找指定字符串位置
[str rangeOfString]
替换
[str stringByReplacingCharactersInRange]
2015-10-28
字符串类型转换
1.c->oc : [NSString stringWithUTF8String]
2.oc->c : [str UTF8String]
格式化字符串
[NSString stringWithFormat]
拼接字符串
[str stringByAppendingString]
大小写转换
1.[str lowercaseString]
2.[str UppercaseString]
判断前后缀
1.[str hasPrefix]
2.[str hasSuffix]
1.c->oc : [NSString stringWithUTF8String]
2.oc->c : [str UTF8String]
格式化字符串
[NSString stringWithFormat]
拼接字符串
[str stringByAppendingString]
大小写转换
1.[str lowercaseString]
2.[str UppercaseString]
判断前后缀
1.[str hasPrefix]
2.[str hasSuffix]
2015-10-28