开发者

Xcode - Comparison of a Double

Hey all, I need to compare a double inside开发者_JAVA技巧 an if statement. If the double has no value/is equal to zero, it should do nothing. Otherwise it should do something.

My if statement if (doubleNameHere > 0) doesn't work.

Obviously I'm missing something fundamental here, any ideas?


Sorry all, it turns out that it wasn't set to zero, it was equal to another blank double value. I started it at zero and it was fine.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜