public static boolean vd(char c){//判断是否是汉字
boolean isUTF = false;
byte []bytes = ("" + c).getBytes();
if(bytes.length > 1){
int []ints = new int[2];
ints[0] = bytes[0]& 0xff;
ints[1] = bytes[1]& 0xff;
if (ints[0] >= 0x81 && ints[0] < 0xFE && ints[1] >= 0x40 && ints[1] <= 0xFE ){
isUTF = true;
}
}
return isUTF;
boolean isUTF = false;
byte []bytes = ("" + c).getBytes();
if(bytes.length > 1){
int []ints = new int[2];
ints[0] = bytes[0]& 0xff;
ints[1] = bytes[1]& 0xff;
if (ints[0] >= 0x81 && ints[0] < 0xFE && ints[1] >= 0x40 && ints[1] <= 0xFE ){
isUTF = true;
}
}
return isUTF;
}
public static void main(String arg[]) throws IOException{
int i=1;
System.out.println(vd('行'));
String out = "sd行";
char[] sb = out.toCharArray();
System.out.println(out.length());
for(int j=0;j<out.length();j++){
System.out.println(vd(sb[j]));
}
}