結果
問題 | No.264 じゃんけん |
ユーザー |
![]() |
提出日時 | 2017-06-21 10:30:20 |
言語 | JavaScript (node v23.5.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 364 bytes |
コンパイル時間 | 43 ms |
コンパイル使用メモリ | 6,816 KB |
実行使用メモリ | 41,588 KB |
最終ジャッジ日時 | 2024-10-13 00:10:01 |
合計ジャッジ時間 | 1,062 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | RE * 9 |
ソースコード
function Main (input) { var line = input.split(' '); var N = +line[0]; var K = +line[1]; game(N,K); } function game (N,K) { if ( N == K) { console.log("Drew"); } else if ( N == K + 1 || N - K == 2){ console.log("Won"); } else { console.log("Lost"); } } Main(require("fs").readFileSync("/dev/stdin") , "utf-8");