3227 - 例题3-3 大小写字母转换(1)
给定一个大写字母A,要求用小写字母输出,同时输出该小写字母对应的ASCII码。
Input
无,初值以赋值的方式给出。
Output
第一行输出小写字母,第二行输出该小写字母对应的ASCII码。注意末尾的换行。
Examples
Input
无
Output
a 97
Solution C
#include<stdio.h> int main() { char c='A'; printf("%c\n%d\n",c+32,c+32); return 0; }
Solution C++
#include<iostream> using namespace std; int main() { cout<<"a"<<endl<<97<<endl; }