結果

問題 No.516 赤と青の風船
ユーザー 多賀悠人多賀悠人
提出日時 2021-06-13 14:58:29
言語 TypeScript
(5.4.3)
結果
WA  
実行時間 -
コード長 804 bytes
コンパイル時間 7,253 ms
コンパイル使用メモリ 253,056 KB
実行使用メモリ 44,932 KB
最終ジャッジ日時 2023-08-24 17:58:53
合計ジャッジ時間 8,632 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

"use strict";
exports.__esModule = true;
var lines = [];
var reader = require('readline').createInterface({
    input: process.stdin,
    output: process.stdout
});
reader.on('line', function (line) {
    lines.push(line);
});
reader.on('close', function () {
    console.log('lines', lines);
    var sum = lines.map(function (line) { return line.trim().length; }).reduce(function (accumulator, currentValue) {
        return accumulator + currentValue;
    });
    console.log('sum', sum);
    if (sum > 10) {
        console.log('BLUE');
    }
    else {
        console.log('RED');
    }
    // ここに処理を書いていく
    // 最後に結果をconsole.log()する
    // 例
    // const hoge: number = parseInt(lines[0])
    // const result: number = hoge * 2
    // console.log(result)
});
0