Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Q1 {
- /* 請撰寫一個程式, 將標準萬國碼中字碼為 97 到 99 之間的字元顯示在螢幕上。 */
- public static void main(String[] args) {
- int unicode = 97;
- for(char unicodeOutput = 97 ; unicodeOutput <= 99 ; unicodeOutput++) { //用for迴圈將char 97~99的值丟給unicodeOutput
- System.out.println("萬國碼 " + unicode + " = " + unicodeOutput); //印出unicodeOutput值
- unicode++;
- }
- }
- }
Add Comment
Please, Sign In to add comment