'(f1==f2)' is
false because the '==' operator checks to see if the
references are identical, i.e., checks to see if the references (f1 f2)
point to the same object. They do not, since you have created separate objects for both references.
'f1.equals(f2)' returns
true since the .equals() method of class
Object is overridden by class
java.lang.Float to check if the objects are 'meaningfully equivalent'--in the way that
String s="abc" and String t="abc" are equivalent.
'Float.NaN==Float.NaN' returns
false because two *.NaN's are, by definition, not equivalent.
Float.NaN!=Float.NaN returns
true, as someone else pointed out.