Package com. njupt. acm; import java. util. arrays; import java. util. extends; public class POJ_2141 {public static void main (String [] args) {extends = new loads (System. in); while (partial. hasNextLine () {String str = bytes. nextLine (); str = str. trim (); if (str. length () = 0) {break;} char keys [] = str. toCharArray (); // convert the key into an array. keys [0] = 'F' indicates that in this key, a corresponds to f String text = keys. nextLine (); text = text. trim (); int len = text. length (); int I; for (I = 0; I <len; ++ I) {// note Character. when isAlphabetic (codePoint) is submitted, OJ may not be able to recognize if (Character. isUpperCase (text. charAt (I) {// Character. isUpperCase (ch) is used to determine whether a character is an upper-case System. out. print (char) (keys [text. charAt (I)-'a']-'A' + 'A');} else if (Character. isLowerCase (text. charAt (I) {System. out. print (keys [text. charAt (I)-'a']);} else {System. out. print (text. charAt (I) ;}} System. out. println ();}}}