結果

問題 No.8 N言っちゃダメゲーム
ユーザー kanra661kanra661
提出日時 2014-12-16 17:05:17
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 495 bytes
コンパイル時間 2,194 ms
コンパイル使用メモリ 71,180 KB
実行使用メモリ 56,168 KB
最終ジャッジ日時 2023-09-02 15:20:34
合計ジャッジ時間 4,712 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 124 ms
55,928 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 AC 152 ms
55,648 KB
testcase_06 AC 150 ms
55,804 KB
testcase_07 AC 149 ms
55,348 KB
testcase_08 AC 148 ms
55,904 KB
testcase_09 AC 150 ms
55,648 KB
testcase_10 AC 150 ms
56,064 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int p = sc.nextInt();
		int n[] = new int[p];
		int k[] = new int[p];
		for(int i=0;i<n.length;i++){
			n[i] = sc.nextInt();
			k[i] = sc.nextInt();
			if(n[i] <= k[i]){
				System.out.println("Win");
			}else if(((n[i]+1)%(k[i]+1)) == 0){
				System.out.println("Lose");
			}else{
				System.out.println("Win");
			}
		}
		sc.close();
	}

}
0