Problem Description
交换两个变量的值,由终端输入两个整数给变量x、y,然后交换x和y的值后,输出x和y。
Input
从键盘输入两个整数变量x和y;
Output
在交换x、y的值后将x和y输出!
Sample Input
4 6
Sample Output
6 4
import java.util.Scanner;
public class Main {
public static void main(String args[]) {
Scanner reader = new Scanner(System.in);
int a = reader.nextInt();
int b = reader.nextInt();
System.out.print(b);
System.out.println(" "+a);
}
}