import java.util.Scanner;
public class Test {
public static void main(String [] args){
Scanner input = new Scanner(System.in);
System.out.print("输入字符串:");
String strs = input.next();
int number = 0;
int chara = 0;
int other = 0;
char [] chs = strs.toCharArray();
for(char c : chs){
if(c >= '0' && c <= '9'){
number++;
}else if(c >= 'a' && c <= 'z' || c >= 'A' && c <= 'Z' ){
chara++;
}else{
other++;
}
}
System.out.println("数字有:" + number + "个,字符有" + chara + "个,其他有:" + other + "个。" );
}
}