結果

問題 No.29 パワーアップ
ユーザー kou_kkk
提出日時 2023-08-24 08:21:21
言語 Nim
(2.2.0)
結果
WA  
実行時間 -
コード長 281 bytes
コンパイル時間 5,856 ms
コンパイル使用メモリ 70,528 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-12-22 19:45:38
合計ジャッジ時間 5,495 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 7 WA * 15
権限があれば一括ダウンロードができます

ソースコード

diff #

import sequtils, strutils, tables

let
  n = parseInt readLine stdin
  abcs = concat n.newSeqWith stdin.readLine.split.map parseInt
var
  cntT = abcs.toCountTable
  cnt = [0, 0]

for i in 1 .. 10:
  cnt = [cnt[0] + cntT[i] div 2, cnt[1] + cntT[i] mod 2]

echo cnt[0] + cnt[1] mod 4
0