开发者

Random Number Generator

- (IBAction)randomnum{
int ra开发者_开发知识库ndomNumber1 = 1+ arc4random() %(49);
label1.text = [NSString stringWithFormat:@"d", randomNumber];

Warning:

Local declaration of randomNumber hides instance variable.

How can i get round this warning?


You had some instance variable of the class with the same name of your randomNumber1 or randomNumber. Recheck for that and change the name, you would be fine

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜