The following code is returning an unexpected (and wrong value).
x1 = ceil(ceil(ceil(100*1.0f)*1.0f)*1.1f);
It is returning 111 not 110. I am aware that multiplying a number by 1 is pointless, but those 1’s are not always ones. When they are other values the function works as expected.
Using the
ceilfoperator fixed it for me: