我正在尝试从名字+姓氏中获取名字和姓氏。intloop=0;NSMutableString*firstname=[[NSMutableStringalloc]init];NSMutableString*fullName=[[NSMutableStringalloc]initWithString:@"Anahita+Havewala"];for(loop=0;([fullNamecharacterAtIndex:loop]!='+');loop++){[firstnameappendString:[NSStringstringWithCharacters:(constunichar*)[
以下尝试打印出N个空格(或示例中的12个):NSLog(@"hello%@world",[NSStringstringWithCharacters:""length:12]);constunichararrayChars[]={''};NSLog(@"hello%@world",[NSStringstringWithCharacters:arrayCharslength:12]);constunicharoneChar='';NSLog(@"hello%@world",[NSStringstringWithCharacters:&oneCharlength:12]);但它们都打印出奇怪
以下尝试打印出N个空格(或示例中的12个):NSLog(@"hello%@world",[NSStringstringWithCharacters:""length:12]);constunichararrayChars[]={''};NSLog(@"hello%@world",[NSStringstringWithCharacters:arrayCharslength:12]);constunicharoneChar='';NSLog(@"hello%@world",[NSStringstringWithCharacters:&oneCharlength:12]);但它们都打印出奇怪