package Scanner;import java.util.Scanner;publicclass 数字计算 {publicstaticvoidmain(String[] args){
Scanner scanner=newScanner(System.in);
String m="";int i=0;int l=0;int sum=0;
System.out.println("请输入第一个数");if(scanner.hasNextInt()){
i = scanner.nextInt();}
System.out.println("请输入第二个数");if(scanner.hasNextInt()){
l = scanner.nextInt();}
System.out.println("请输入符号");if(scanner.hasNext()){
m=scanner.next();}switch(m){case"+":
sum = i + l;break;case"-":
sum = i - l;break;case"*":
sum = i * l;break;case"/":
sum = i / l;break;case"%":
sum = i % l;break;default:
System.out.println("你的输入不合法!!!");}
System.out.println(sum);}}
package Scanner;import java.util.Scanner;public class 数字计算 { public static void main(String[] args) { Scanner scanner=new Scanner(System.in); String m=""; int i=0; int l=0; int sum=0; System.out.print