首先定义: java.text.DecimalFormat df=new java.text.DecimalFormat("#0.00"); 再是:x = 83.3333333333;df.format(x); 结果: 83.33