哪位大神能够帮我解答下 键盘录入的代码格式,和具体的解析啊!
//import java.util.Scanner;
class Test1_Operator {
public static void main(String[] args) {
/*Scanner sc = new Scanner(System.in);
System.out.println("请输入一个整数");
int x = sc.nextInt();
System.out.println("个位:"+ x%10);
System.out.println("十位:"+ x / 10 %10);
System.out.println("百位:"+ x / 10 /10 %10);
System.out.println("千位:"+ x / 10 / 10 / 10 %10);谢谢啦! |
|