3856 {
3857 char matrix[26][7][5];
3858 for(int i = 0; i < 26; i++) {
3859 for(int j = 0; j < 7; j++) {
3860 for(int k = 0; k < 5; k++) {
3861 cin >> matrix[i][j][k];
3862 }
3863 }
3864 }
3865 vector<string> vec;
3866 ostringstream oss;
3867 char ch;
3868 cin >> noskipws;
3869 while(cin >> ch) {
3870 if(isupper(ch) != 0) {
3871 oss << ch;
3872 } else {
3873 if(!oss.str().empty()) {
3874 vec.emplace_back(oss.str());
3875 }
3876 oss = ostringstream();
3877 }
3878 }
3879 if(!oss.str().empty()) {
3880 vec.emplace_back(oss.str());
3881 }
3882 int cnt = 0;
3883 for(const auto &str: vec) {
3884 const int w = str.length() * 6 - 1;
3885 vector output(7, vector(w, ' '));
3886 for(int i = 0; i < str.length(); i++) {
3887 const char c = str[i];
3888 for(int j = 0; j < 7; j++) {
3889 for(int k = 0; k < 5; k++) {
3890 output[j][i * 6 + k] = matrix[c - 'A'][j][k];
3891 }
3892 }
3893 }
3894 for(int i = 0; i < 7; i++) {
3895 for(int j = 0; j < w; j++) {
3896 cout << output[i][j];
3897 }
3898 if(i != 6) {
3899 cout << endl;
3900 }
3901 }
3902 if(cnt++ !=
vec.size() - 1) {
3903 cout << endl
3904 << endl;
3905 }
3906 }
3907 return 0;
3908 }