結果
問題 | No.264 じゃんけん |
ユーザー |
|
提出日時 | 2021-08-02 00:02:06 |
言語 | JavaScript (node v23.5.0) |
結果 |
AC
|
実行時間 | 60 ms / 5,000 ms |
コード長 | 955 bytes |
コンパイル時間 | 115 ms |
コンパイル使用メモリ | 5,120 KB |
実行使用メモリ | 39,296 KB |
最終ジャッジ日時 | 2024-09-16 13:05:05 |
合計ジャッジ時間 | 1,488 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 9 |
ソースコード
"use strict"; function Main(input) { let MyHand; let OtHand; [MyHand, OtHand] = input.split(" ").map(i => Number(i)); if (MyHand === OtHand) { console.log("Drew"); } else { if (MyHand === 0) { if (OtHand === 1) { console.log("Won"); } else { console.log("Lost"); } } else if (MyHand === 1) { if (OtHand === 2) { console.log("Won"); } else { console.log("Lost"); } } else if (MyHand === 2) { if (OtHand === 0) { console.log("Won"); } else { console.log("Lost"); } } } } //テストの入力を受け取る Main(require("fs").readFileSync("/dev/stdin", "utf8")); //# sourceMappingURL=index.js.map