//本事例去除小括号及其内部的内容
+ (NSString *)changeStringWithString:(NSString *)string
{
NSScanner*scanner = [NSScanner scannerWithString:string];
NSString*str =nil;
while([scanner isAtEnd]==NO)
{
//找到"("的起始位置
[scanner scanUpToString:@"("intoString:nil];
//找到")"的结束位置
[scanner scanUpToString:@")"intoString:&str];
}
NSString *lastString = [str stringByAppendingString:@")"];
return lastString;
}