4 条题解

  • 2
    @ 2025-3-7 11:10:31
    dic={"a":'z',"b":"y","c":"x","d":"w","e":"v","f":"u","g":"t","h":"s","i":"r","j":'q',"k":"p","l":"o","m":"n","n":"m","o":"l","p":"k","q":"j","r":"i","s":"h","t":"g","u":"f","v":"e","w":"d","x":"c","y":"b","z":"a"}
    a=str(input())
    b=len(a)
    for i in a:
        if i in dic:
            print(dic[i],end="")
        else:
            print(i,end="")
    
    • 0
      @ 2023-7-17 15:14:05
      #include <iostream>
      #include <cstdio>
      #include<string>
      using namespace std;
      int main(){
          string str;
          getline(cin,str);
          for(int i=0;i<str.length();i++){
              if(str[i]>='a'&&str[i]<='z'){
                  str[i]='z'+'a'-str[i];
              }
          }
          cout<<str;
          return 0;
      }
      

      c++

      • -2
        @ 2022-7-12 10:28:59

        #include<bits/stdc++.h> using namespace std; int main(){ string b;int c; getline(cin,b); for(c=0;c<b.length();c++){ if(b[c]>='a' && b[c]<='z'){ b[c]='z'+'a'-b[c]; } } cout<<b; }

        • -3
          @ 2023-7-17 20:08:23

          #include <bits/stdc++.h>

          using namespace std;

          int main() { string a; int b=0; while(cin>>a){ cout<<a; b=b+a.length(); }

          cout<<endl;
          cout<<b;
          return 0;
          

          }

          • 1

          信息

          ID
          74
          时间
          1000ms
          内存
          128MiB
          难度
          5
          标签
          递交数
          684
          已通过
          286
          上传者