float result = (float) (Math.round (result * 10)) / 10;要是保留两位:10 --> 100, 以此类推. 转载于:https://blog.51cto.com/5934497/1588690