d498: 我不說髒話
題目:http://zerojudge.tw/ShowProblem?problemid=d498
程式碼:
程式碼:
import java.util.Scanner;
public class d498 {
 public static void main(String[] args) {
  // TODO Auto-generated method stub
  Scanner sc= new Scanner(System.in);
  while(sc.hasNext()){
   int n = sc.nextInt();//輸入數字
   while(n>=1){
    System.out.println("I don't say swear words!");
    n--;
   }
  }
 }
}

留言
張貼留言