提交时间:2020-08-23 19:14:20

运行 ID: 6057

#include<bits/stdc++.h> using namespace std; int main(){ int t; int s; cin>>t; char a[11]={'O','O','T','T','F','F','S','S','E','N'}; for(int i=1;i<=t;i++){ cin>>s; int s1=s,z=0; for(;s1!=0;){ s1/=10; z++; } int s2=s; for(int j=z;j>=1;j--){ int b=s2%10; s2/=10; if(b==0) cout<<'O'; else cout<<a[b]; } cout<<endl; } return 0; }