float f = 120.25f;
System.out.println(Integer.toHexString(Float.floatToIntBits(f)));
浮点数f用这种方式转化成16进制后怎么反向转化,即将得到的16进制,转换回原来的浮点数?
------解决方案--------------------
System.out.println(Float.intBitsToFloat(Integer.parseInt("42f08000", 16)));
System.out.println(Float.intBitsToFloat(Integer.parseInt("42f08000", 16)));