问题:
Is it possible to do this?是否有可能做到这一点?
double variable;
variable = 5;
/* the below should return true, since 5 is an int.
if variable were to equal 5.7, then it would return false. */
if(variable == int) {
//do stuff
}
I know the code probably doesn't go anything like that, but how does it go?我知道代码可能不会去这样的事情,但它是如何走?
解决方案:
参考一: https://en.stackoom.com/question/fX3Q参考二: https://stackoom.com/question/fX3Q