結果

問題 No.231 めぐるはめぐる (1)
ユーザー kenji_shioyakenji_shioya
提出日時 2016-06-09 06:23:45
言語 Java21
(openjdk 21)
結果
AC  
実行時間 195 ms / 1,000 ms
コード長 514 bytes
コンパイル時間 3,389 ms
コンパイル使用メモリ 74,736 KB
実行使用メモリ 56,752 KB
最終ジャッジ日時 2024-04-25 13:11:00
合計ジャッジ時間 6,497 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 192 ms
56,752 KB
testcase_01 AC 168 ms
54,384 KB
testcase_02 AC 141 ms
54,336 KB
testcase_03 AC 178 ms
54,636 KB
testcase_04 AC 195 ms
56,520 KB
testcase_05 AC 181 ms
54,624 KB
testcase_06 AC 191 ms
54,544 KB
testcase_07 AC 170 ms
54,096 KB
testcase_08 AC 179 ms
54,248 KB
testcase_09 AC 131 ms
54,208 KB
testcase_10 AC 129 ms
54,252 KB
testcase_11 AC 127 ms
54,152 KB
testcase_12 AC 179 ms
54,264 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Exercise70{
  public static void main (String[] args){

    Scanner sc = new Scanner(System.in);



    int n = sc.nextInt();
    int a = -1;
    for(int i = 0; i < n; i++){
      int g = sc.nextInt();
      int d = sc.nextInt();
      if(g - (d * 30000) >= 3000000 / 6){
        a = i + 1;
      }
    }
    if(a > 0){
      System.out.println("YES");
      for(int i = 0; i < 6; i++){
        System.out.println(a);
      }
    }else{
      System.out.println("NO");
    }
  }
}
0