結果

問題 No.191 供託金
ユーザー Takuya-AmpiTakuya-Ampi
提出日時 2020-03-28 21:42:10
言語 JavaScript
(node v23.5.0)
結果
AC  
実行時間 82 ms / 5,000 ms
コード長 444 bytes
コンパイル時間 53 ms
コンパイル使用メモリ 6,820 KB
実行使用メモリ 42,172 KB
最終ジャッジ日時 2024-10-13 01:37:08
合計ジャッジ時間 3,054 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

const reader = require("readline").createInterface({
  input: process.stdin,
  output: process.stdout
});
let lines = [];
reader.on("line", line => {
  lines.push(line);
});
reader.on("close", () => {
  // const candidates = parseInt(lines[0])
  let votes = lines[1].split(' ').map(str => parseInt(str, 10))
  const sum = votes.reduce((a, c) => a + c)
  const check = votes.filter(item => item <= sum / 10)
  console.log(30 * check.length)
});
0