返回列表 發帖
  1. package date0605;
  2. import java.util.Scanner;
  3. public class JPA02
  4. {
  5.         static Scanner keyboard = new Scanner(System.in);
  6.     public static void main(String[] args)
  7.     {
  8.         test();
  9.         System.out.println("End");
  10.         test();
  11.         System.out.println("End");
  12.     }
  13.    
  14.     public static void test()
  15.     {
  16.             int num;
  17.             System.out.println("Please enter score:");
  18.             num = keyboard.nextInt();
  19.             if(num>60)
  20.             {
  21.                     System.out.println("You pass");
  22.             }
  23.     }
  24. }
複製代碼

TOP

返回列表