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.
精彩评论