結果

問題 No.8 N言っちゃダメゲーム
ユーザー chiho_miyakochiho_miyako
提出日時 2015-04-10 13:11:14
言語 Java21
(openjdk 21)
結果
AC  
実行時間 150 ms / 5,000 ms
コード長 519 bytes
コンパイル時間 2,055 ms
コンパイル使用メモリ 71,816 KB
実行使用メモリ 56,264 KB
最終ジャッジ日時 2023-09-17 19:09:31
合計ジャッジ時間 4,293 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 121 ms
55,836 KB
testcase_01 AC 122 ms
55,624 KB
testcase_02 AC 121 ms
55,436 KB
testcase_03 AC 145 ms
55,860 KB
testcase_04 AC 146 ms
55,556 KB
testcase_05 AC 146 ms
55,840 KB
testcase_06 AC 146 ms
56,152 KB
testcase_07 AC 145 ms
55,888 KB
testcase_08 AC 144 ms
56,128 KB
testcase_09 AC 147 ms
55,856 KB
testcase_10 AC 150 ms
56,264 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
public class Main {
    public static void main(String[] args) throws Exception {
        Scanner koko = new Scanner(System.in);
        int p = koko.nextInt();
        int[] n = new int[p];
        int[] k = new int[p];
        for(int i=0; i<p; i++){
            n[i] = koko.nextInt();
            k[i] = koko.nextInt();
            if((n[i]-1)%(k[i]+1)==0){
                System.out.println("Lose");
            }else{
                System.out.println("Win");
            }
        }
    }
}
0