結果

問題 No.8 N言っちゃダメゲーム
ユーザー nak2yoshi
提出日時 2016-02-25 11:25:42
言語 D
(dmd 2.109.1)
結果
AC  
実行時間 1 ms / 5,000 ms
コード長 408 bytes
コンパイル時間 725 ms
コンパイル使用メモリ 110,208 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-06-12 03:07:04
合計ジャッジ時間 1,312 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 11
権限があれば一括ダウンロードができます

ソースコード

diff #

import std.stdio,
       std.conv,
       std.string,
       std.range,
       std.math,
       std.bigint,
       std.algorithm;

void main()
{
    auto P = readln.strip.to!int;
    int[] N, K;
    foreach (_; 0 .. P)
    {
        auto input = readln.split.to!(int[]);
        N ~= input[0];
        K ~= input[1];
    }

    iota(P).each!(i => (N[i]<=K[i]?"Win":N[i]%(K[i]+1)==1?"Lose":"Win").writeln);
}
0