MATLAB: I have no idea why matlab does not understand this simple if function, any idea

bugfor loopif statement

Simply put, this if condition never gets satisfied. It does work for other ns like 0 0.2,1.6,2 etc but does not work for n==1.2. Is this a software bug? I am using Matlab R2012a
for n=0:0.2:2
if n==1.2
test1=1
end
end
Thanks
Related Question