I am new to lua, and i am using it to automate some tasks in the simulation program femm. In my script i have this type of for loop:
for i=0.1,0.3,0.1
do
print(i)
end
The problem is it only iterates from 0.1 to 0.2(it does not enter i=0.3).I tried with other values (for example from 0.1 to 0.4) and it works properly. Why does this strange behaviour happen? Is this a floating point number problem?