結果

問題 No.56 消費税
ユーザー ontama_12
提出日時 2016-09-23 14:19:19
言語 JavaScript
(node v23.5.0)
結果
AC  
実行時間 80 ms / 5,000 ms
コード長 549 bytes
コンパイル時間 30 ms
コンパイル使用メモリ 6,692 KB
実行使用メモリ 42,228 KB
最終ジャッジ日時 2024-10-12 23:46:46
合計ジャッジ時間 2,927 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

    //入力文字読み取り
    process.stdin.resume();
    process.stdin.setEncoding('utf8');
    process.stdin.on('data', function (chunk) {


        //すべて受け取り改行で区切って格納
        var inputAllLines = chunk.split(" ");
        //商品
        var product = Number(inputAllLines[0])
        //消費税
        var tax = Number(inputAllLines[1])

        //消費税の計算
        consumptiontax = product * tax / 100
        var result = Math.floor(product + consumptiontax)

        console.log(result)
    });
0