Objective c Nslog文本数据?
如何将NSlogs中的数据放入以下内容:Objective c Nslog文本数据?,objective-c,Objective C,如何将NSlogs中的数据放入以下内容: [tweetSheet setInitialText:@"I just scored xx 'touches'"]; NSlog NSLog(@"Game over score: %i",counter); 产出 2012-01-06 04:27:00.296 [317:707] Game over score: **31** 31我想在第一行代码中的xx上使用NSString的-stringWithFormat:方法: [tweetSheet s
[tweetSheet setInitialText:@"I just scored xx 'touches'"];
NSlog
NSLog(@"Game over score: %i",counter);
产出
2012-01-06 04:27:00.296 [317:707] Game over score: **31**
31我想在第一行代码中的xx上使用
NSString
的-stringWithFormat:
方法:
[tweetSheet setInitialText:[NSString stringWithFormat:@"I just scored %d 'touches'", counter]];
使用
NSString
的-stringWithFormat:
方法:
[tweetSheet setInitialText:[NSString stringWithFormat:@"I just scored %d 'touches'", counter]];