本帖最後由 李泳霖 於 2022-7-2 20:33 編輯
TQC408- import java.util.Scanner;
- public class JPD04 {
- static Scanner keyboard = new Scanner(System.in);
- public static void main(String args[]) {
- String s, c;
- System.out.print("Input a string: ");
- s = keyboard.nextLine();
- System.out.printf("%s\n", reverse(s));
- System.out.print("Input a string: ");
- s = keyboard.nextLine();
- System.out.printf("%s\n", reverse(s));
- }
-
- ...
- }
複製代碼 TQC504- import java.util.Scanner;
- public class JPD05 {
- public static Scanner keyboard = new Scanner(System.in);
-
- public static void main(String[] argv) {
-
-
-
-
-
- }
- }
複製代碼 |