文件名称:qd
介绍说明--下载内容均来自于网络,请自行研究使用
本例要求判别键盘输入字符的类别。可以根据输入字符的ASCII码来判别类型。由ASCII码表可知ASCII值小于32的为控制字符。 在“0”和“9”之间的为数字,在“A”和“Z”之间为大写字母, 在“a”和“z”之间为小写字母,其余则为其它字符。 这是一个多分
支选择的问题,用if-else-if语句编程,判断输入字符ASCII码所在的范围,分别给出不同的输出。例如输入为“g”,输出显示它为小写字符。
-Requirements in this case determine the type of keyboard input characters. Can input ASCII characters to determine the type of code. ASCII code table, we can see by the ASCII value for the control of less than 32 characters. In " 0" and " 9" between the digital, in the " A" and " Z" between the capital letters in the " a" and " z" for the lowercase letters between, while the rest is the other characters. This is a choice of multi-branch, the if-else-if statements programming, ASCII character code input to determine the scope of which were given different output. For example, input for the " g" , the output shows that it is lower-case characters.
支选择的问题,用if-else-if语句编程,判断输入字符ASCII码所在的范围,分别给出不同的输出。例如输入为“g”,输出显示它为小写字符。
-Requirements in this case determine the type of keyboard input characters. Can input ASCII characters to determine the type of code. ASCII code table, we can see by the ASCII value for the control of less than 32 characters. In " 0" and " 9" between the digital, in the " A" and " Z" between the capital letters in the " a" and " z" for the lowercase letters between, while the rest is the other characters. This is a choice of multi-branch, the if-else-if statements programming, ASCII character code input to determine the scope of which were given different output. For example, input for the " g" , the output shows that it is lower-case characters.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
qd.doc