1
#include<iostream>
#include<iomanip>
using namespace std;
int main()
{
char ch;
cin>>ch;
cout<<(int)ch;
return 0;
}
2
#include<iostream>
#include<iomanip>
using namespace std;
int main()
{
char ch;
cin>>ch;
if((int)ch>=65 && (int)ch<=90)
{
cout<<"YES";
}
else
{
cout<<"NO";
}
return 0;
}
3
#include<iomanip>
using namespace std;
int main()
{
char ch;
cin>>ch;
ch = ch - 32;
cout<<ch;
return 0;
}
4
#include<iostream>
#include<iomanip>
using namespace std;
int main()
{
char ch;
cin>>ch;
ch = ch + 32;
cout<<ch;
return 0;
}
5
#include<iostream>
#include<iomanip>
using namespace std;
int main()
{
for(int i = 65;i<=90;i++)
{
cout<<(char)i<<" ";
if(i == 77)
{
cout<<endl;
}
}
cout<<endl;
for(int i = 90;i>=65;i--)
{
cout<<(char)i<<" ";
if(i == 78)
{
cout<<endl;
}
}
return 0;
}
10.29作业
最新推荐文章于 2024-08-16 16:51:12 发布