結果

問題 No.8 N言っちゃダメゲーム
ユーザー shinwisteriashinwisteria
提出日時 2017-03-30 17:56:51
言語 Java21
(openjdk 21)
結果
AC  
実行時間 149 ms / 5,000 ms
コード長 443 bytes
コンパイル時間 3,169 ms
コンパイル使用メモリ 73,404 KB
実行使用メモリ 56,640 KB
最終ジャッジ日時 2023-09-21 08:44:20
合計ジャッジ時間 6,003 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 125 ms
55,816 KB
testcase_01 AC 126 ms
56,220 KB
testcase_02 AC 125 ms
56,136 KB
testcase_03 AC 146 ms
56,640 KB
testcase_04 AC 147 ms
56,276 KB
testcase_05 AC 148 ms
55,992 KB
testcase_06 AC 148 ms
56,264 KB
testcase_07 AC 148 ms
55,908 KB
testcase_08 AC 149 ms
56,252 KB
testcase_09 AC 149 ms
56,064 KB
testcase_10 AC 147 ms
56,432 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class No21game {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		int P = s.nextInt();
		int[][] nk = new int[P][2];
		for(int i = 0;i < P;i++){
			nk[i][0] = s.nextInt();
			nk[i][1] = s.nextInt();
		}
		s.close();

		for(int i =0; i < P;i++){
			if((nk[i][0] - 1) % (nk[i][1]+1) == 0){
				System.out.println("Lose");
			}else{
				System.out.println("Win");
			}
		}
	}

}
0