#include<bits/stdc++.h>#include<windows.h>#include<cstdlib>using namespace std;
#define L long long
string a = "ECDFIGBJOKLMNHUQRSTPAWXYZV", b = "ecdfigbjoklmnhuqrstpawxyzv";
signed main()
{
ios::sync_with_stdio ( 0 );
cin.tie ( 0 );
cout.tie ( 0 );
string s;
while ( getline ( cin, s ) )
{
for ( char &i : s )
{
if ( 'a' <= i && i <= 'z' )
{
i = b[i - 'a'];
}
if ( 'A' <= i && i <= 'Z' )
{
i = a[i - 'A'];
}
}
cout << s << ' ';
}
return 0;
}
to normal:
C++
#include<bits/stdc++.h>#include<windows.h>#include<cstdlib>using namespace std;
#define L long long
string a = "UGBCADFNEHJKLMITPQRSOZVWXY", b = "ugbcadfnehjklmitpqrsozvwxy";
signed main()
{
ios::sync_with_stdio ( 0 );
cin.tie ( 0 );
cout.tie ( 0 );
string s;
while ( getline ( cin, s ) )
{
for ( char &i : s )
{
if ( 'a' <= i && i <= 'z' )
{
i = b[i - 'a'];
}
if ( 'A' <= i && i <= 'Z' )
{
i = a[i - 'A'];
}
}
cout << s << '\n';
}
return 0;
}