public class youni{
public static void main (String[] args){
int a = 1;
int b = 2;
//1 借助第三变量进行交换
/*int temp = b;
b = a;
a = temp;
System.out.println(a);
System.out.println(b);
不借助第三变量实现交换
*/
a = a + b;
b = a - b;
a = a - b;
03-09
752
06-11
2281
07-26
3627
06-11
2万+