UVA 11150 Java

  1. import java.util.*;
  2. import static java.lang.System.*;
  3. public class main{
  4. public static void main(String[] args) {
  5. Scanner sc=new Scanner(System.in);
  6. while(sc.hasNextInt())
  7. {
  8. int n = sc.nextInt();
  9. System.out.println(n + n / 2);
  10. }
  11. }
  12. };
  13.  

留言

這個網誌中的熱門文章

C# 井字遊戲