嵌套语句应该怎么写
Scanner sc=new Scanner(System.in); System.out.println("请输入一个10位以内的数字"); long num=sc.nextInt(); int count=0; while (num>0){ count++; num=num/10; } System.out.println(count+"位数");
Scanner sc=new Scanner(System.in); System.out.println("请输入一个10位以内的数字"); long num=sc.nextInt(); int count=0; while (num>0){ count++; num=num/10; } System.out.println(count+"位数");
2022-03-17
举报