Xcode'NSinteger'(aka'int')?这样做了吗?

时间:2012-09-08 19:39:15

标签: xcode

NSString *nssHighscore = [NSString stringWithFormat:@"Bounce the ball upwards by tilting or touching where you want it to go. Bounce on the green platforms in order to move up. If you miss a platform and fall, it's game over.%lu",highscore];

Xcodes问道:'NSinteger'(又名'int')

我必须把这个'NSinteger'(aka'int')放在代码上。

1 个答案:

答案 0 :(得分:1)

格式说明符%lu用于unsigned long整数。如果要指定%d整数的格式,请使用int。 Apple在Developer Connection网站上有这些和其他格式说明符的表格。