/*
第6题 字符串内所有a都替换成A;
*/
NSString *[email protected]"whatareyou";
str7=[str7 stringByReplacingOccurrencesOfString:@"a" withString:@"A"];
NSLog(@"第六题:\n");
NSLog(@"%@",str7);
时间: 2024-11-05 17:33:28
/*
第6题 字符串内所有a都替换成A;
*/
NSString *[email protected]"whatareyou";
str7=[str7 stringByReplacingOccurrencesOfString:@"a" withString:@"A"];
NSLog(@"第六题:\n");
NSLog(@"%@",str7);