Ending、Java算法(2)-打印字符的ASCII码

时间:2023-01-15 11:28:53

package com.six.oneseven;

//打印字符的ACSII码
public class Two {

	public void disAcsii(char ch){
		int iTmp=(int)ch;
		System.out.println(ch+"的Ascii码是"+iTmp);
	}
	
	public static void main(String[] args) {
		Two two=new Two();
		two.disAcsii('0');
		two.disAcsii('9');
		two.disAcsii('A');
		two.disAcsii('Z');
		two.disAcsii('a');
		two.disAcsii('z');
	}

}

java程序——打印字符的ASCII码

Ending、Java算法(2)-打印字符的ASCII码