TOPIC

5 % de wrong answer

roberto asked 7 months ago

include include

using namespace std; int n; string frs; int main() { cin>>n; for(int v=0;v<n;v++) { getline(cin,frs); for(int c=frs.size()-1;c >= 0;c--) { if(frs[c] >= 65 && frs[c] <= 90 || frs[c] >= 97 && frs[c] <= 122) frs[c]+=3; if(c <= frs.size()/2) frs[c]--; } reverse(frs.begin(),frs.end()); cout<<frs<<"\n"; frs.clear(); } }

Remember not post solutions. Your post may be reviewed by our moderators.

  • Aléxis Toigo replied 7 months ago

    Use ctrl+alt+c para postar seu código.