package Demo01;//Scanner计算和值
import java.sql.SQLOutput;
import java.util.Scanner;
/题目要求-键盘输入两个数字,并且求和/
public class demo02ScannerSum {
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
System.out.println(“请输入第一个数字”);
int num1=sc.nextInt();
System.out.println(“num1:”+num1);
System.out.println(“请输入第二个数字”);
int num2=sc.nextInt();
System.out.println(“num2:”+num2);
System.out.println(num1+num2);
}
}