I need to check if a variable is a whole number, say I have the code:
double foobar = 3;
//Pseudocode
if (foobar == whole)
cout << "It's whole";
else
cout << "Not whole";
How would I do this?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…