返回列表 發帖
  1. import java.util.Scanner;
  2. public class Ch01
  3. {
  4.         static void hello(int n)
  5.         {
  6.                 for(int i=1; i<=n; i++)
  7.                         System.out.println("Hello!");
  8.         }
  9.         static int myplus(int a,int b,int c)
  10.         {
  11.                 return a+b+c;
  12.         }
  13.         public static void main(String[] args)
  14.         {
  15.                 hello(5);
  16.                 System.out.println(myplus(1,2,3));
  17.         }
  18. }
複製代碼

TOP

返回列表