結果

問題 No.1883 SLASH
ユーザー Fullmoon8507
提出日時 2022-09-24 15:04:20
言語 JavaScript
(node v23.5.0)
結果
AC  
実行時間 72 ms / 2,000 ms
コード長 438 bytes
コンパイル時間 57 ms
コンパイル使用メモリ 5,248 KB
実行使用メモリ 39,296 KB
最終ジャッジ日時 2024-12-22 05:57:11
合計ジャッジ時間 2,086 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 13
権限があれば一括ダウンロードができます

ソースコード

diff #

function Main(input) {
    'use strict';
    let data = input.split("\n");
    let first_line = data[0].split("");
    let second_line = data[1];

    let num_list = new Array();
    for (let x of first_line) {
        num_list.push(parseInt(x));
    }

    let max = Math.max(...num_list);
    let min = Math.min(...num_list);
    console.log(max-min);
}

// Don't edit this line!
Main(require("fs").readFileSync("/dev/stdin", "utf8")); 
0