lingyun


私信TA

用户名:15210020303

访问量:71583

签 名:

喝水的鱼

等  级
排  名 26
经  验 15362
参赛次数 8
文章发表 152
年  龄 19
在职情况 学生
学  校 安徽建筑大学
专  业 电气

  自我简介:

程序爱好者

解题思路:

注意事项:

参考代码:

#include<iostream>
#include<string>
using namespace std;
int main()
{
	string str;
	while(getline(cin,str))
	{
		if(str=="END")
		break;
		int n=str.size();
		for(int i=0;i<n;i++)
		{
			char ch=str[i];
			if(ch=='A'||ch=='W'||ch=='F')
			str[i]='I';
			else if(ch=='D'||ch=='P'||ch=='G'||ch=='B')
			str[i]='e';
			else if(ch=='C')
			str[i]='L';
			else if(ch=='M')
			str[i]='o';
			else if(ch=='S')
			str[i]='v';
			else if(ch=='L')
			str[i]='Y';
			else if(ch=='X')
			str[i]='u';
		}
		cout<<str<<endl;
	}
	return 0;
}


 

0.0分

0 人评分

  评论区