double num1 =11;

double num1 =21;

String num1 ="";

DecimalFormat df = new DecimalFormat(".00");
num3 = df.format((num1 - num2)/num2*100);

Sytem.out.println(num3);

运行结果:

num3=52.38

相关文章:

  • 2021-12-07
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-06-20
  • 2021-12-31
  • 2022-12-23
  • 2022-01-19
  • 2021-07-28
  • 2021-08-07
  • 2021-12-06
相关资源
相似解决方案