对比答案中的速度
public class HelloWorld{
public static void main(String[] args) {
int one = 10 ;
int two = 20 ;
int three=0;
three =one+two;
System.out.println("three=one+two==>"+three+"\t");
System.out.println("three+=one==>"+(three+=one)+"\t");
System.out.println("three-=one==>"+(three-=one)+"\t");
System.out.println("three*=one==>"+(three*=one)+"\t");
System.out.println("three/=one==>"+(three/=one)+"\t");
System.out.println("three%=one==>"+(three%=one)+"\t");
}
}
为什么每条都要加呢? 直接输出代码不是会少点,速度会快点