結果

問題 No.2789 hako111223’s Master Thesis
ユーザー YU Hirose
提出日時 2024-07-22 21:18:35
言語 JavaScript
(node v23.5.0)
結果
AC  
実行時間 83 ms / 2,000 ms
コード長 315 bytes
コンパイル時間 294 ms
コンパイル使用メモリ 6,944 KB
実行使用メモリ 39,552 KB
最終ジャッジ日時 2024-07-22 21:18:40
合計ジャッジ時間 4,748 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 15
権限があれば一括ダウンロードができます

ソースコード

diff #

function Main(input) {
    input = input.trim().split("\n");
    const [a, b, c, d] = input[0].trim().split(" ").map(Number);
    let p = 31 - a + b;
    let res;
    if (p >= c) res = 1;
    else if (p >= d) res = 2;
    else res = 3;
    console.log(res);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
0