The explanation is not an easy one to give but you may be able to work it out.

1.0 and 1.5 work fine. What about 1.25, 1.125, 1.0625, 1.03125? You may be able to think of others in this sequence.
What are the above numbers in binary? E.g. 1.0_10=1.0_2. 1.5_10=1.1_2. 1.25_10=1.01_2 (_10 and _2 mean "base 10" and "base 2").
What are the binary representations of the numbers where the equality test fails, (a) in float precision; (b) in double precision?
What if i and j could store decimal numbers exactly, and, say, i=1.333 and j=1.333333. Should the test i==j return TRUE or FALSE?

By working through the above you'll learn a heck of a lot more than if I just gave you the answer directly.