IOS, IOS Questions, Objective-c, Programming

How To Remove and Replace String within a String.

// Here We Deleting Something
NSString *content = @”i am a good boy”;
NSCharacterSet *deleteString = [NSCharacterSet characterSetWithCharactersInString:@”good”];
content = [[content componentsSeparatedByCharactersInSet: deleteString] componentsJoinedByString: @””];
NSLog(@”String===>>>%@”, content);

// Here We Replace Something
NSString *replaceString = @”i am a good boy”;
replaceString = [replaceString stringByReplacingOccurrencesOfString:@”boy” withString:@”Man”];
NSLog(@”Replace String===>>>%@”, replaceString);