1.2 * w 36.0. It has a double type, meaning that it is not represented accurately.
It will probably turn out to be a little smaller 36, maybe 35.99999, therefore, when you return it, the fractional part is discarded and only the integer part is returned. How do you get 35.
P.S. . . , , , .
: if (value == 36.0) { /* ... */ }
: if (abs (value - 36.0) < 0.0001) { /* ... */ }
user151323