結果

問題 No.987 N×Mマス計算(基本)
ユーザー mnao305mnao305
提出日時 2020-02-14 21:57:19
言語 JavaScript
(node v21.7.1)
結果
WA  
実行時間 -
コード長 461 bytes
コンパイル時間 63 ms
コンパイル使用メモリ 6,816 KB
実行使用メモリ 50,912 KB
最終ジャッジ日時 2024-04-21 03:07:42
合計ジャッジ時間 4,104 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
38,912 KB
testcase_01 AC 74 ms
39,168 KB
testcase_02 AC 169 ms
44,288 KB
testcase_03 AC 100 ms
40,832 KB
testcase_04 AC 150 ms
43,648 KB
testcase_05 AC 130 ms
42,624 KB
testcase_06 AC 151 ms
43,520 KB
testcase_07 AC 112 ms
41,600 KB
testcase_08 AC 79 ms
39,552 KB
testcase_09 AC 79 ms
39,424 KB
testcase_10 WA -
testcase_11 AC 185 ms
43,648 KB
testcase_12 WA -
testcase_13 WA -
testcase_14 AC 76 ms
39,296 KB
testcase_15 AC 113 ms
41,600 KB
testcase_16 AC 192 ms
48,512 KB
testcase_17 WA -
testcase_18 AC 192 ms
48,896 KB
testcase_19 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

"use strict"

const main = (INPUT) => {
  const input = INPUT.split("\n")
  const N = input[0].split(' ')[0]
  const M = input[0].split(' ')[1]
  input.shift()
  const b = input[0].split(" ")
  const op = b.shift()
  input.shift()
  for (let i = 0; i < N; i++) {
    let ans = ""
    for (let j = 0; j < M; j++) {
      ans += ` ${eval(`${input[i]}${op}${b[j]}`)}`
    }
    console.log(ans.trim())
  }
}

main(require("fs").readFileSync("/dev/stdin", "utf8"))
0