时间限制:1.0s 内存限制:512.0MB
编写函数,判断某个给定字符是否为数字。 样例输入
9
样例输出
yes
代码如下:
#include<stdio.h> int main() { char x; scanf("%c",&x); if (x >= '0' && x <= '9') { printf("yes"); } else { printf("no"); } return 0; }