Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在十进制格式#.##的帮助下在android中做了一个应用程序。但我需要得到小数的前两位小数。我不想四舍五入。有没有任何编码请告诉我
采用DecimalFormat.setRoundingMode(RoundingMode.DOWN);
DecimalFormat.setRoundingMode(RoundingMode.DOWN);
参考