#include<iostream> using namespace std; int main(){ char a[1024]; char b[1024]; char xx[]="0abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; int i=0; cin>>a; while (a[i]!='\0') { if (a[i]>96) { int small=a[i]-96; small=(small*small+small+1)%52; b[i]=xx[small]; } else { int big=a[i]-38; big=(big*big+big+1)%52; b[i]=xx[big]; } i++; } b[i]='\0'; cout<<b<<endl; return 0; }
字母加密
最新推荐文章于 2023-10-22 21:16:29 发布