"Is Integer" Condition

To do what you want you need Y not to be an integer, but a float then you have to use **truncate **on Y and then convert the result to float and compare the two(original Y and truncated version). If the rounded version is identical to the float then the original float is, mathematically, an integer. Again, you can need a float as the result to check if it’s float or int, if you wish you can keep the result temporary on a different variable and assign it to Y after the integer check.