結果

問題 No.99 ジャンピング駒
コンテスト
ユーザー むらため
提出日時 2019-01-16 19:09:56
言語 Nim
(2.2.8)
コンパイル:
nim --nimcache=~ --hints:off -o:a.out -d:release cpp _filename_
実行:
./a.out
結果
AC  
実行時間 9 ms / 5,000 ms
コード長 377 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,596 ms
コンパイル使用メモリ 68,056 KB
実行使用メモリ 7,844 KB
最終ジャッジ日時 2026-03-22 01:59:06
合計ジャッジ時間 2,046 ms
ジャッジサーバーID
(参考情報)
judge2_0 / judge1_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 6
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

proc printf(formatstr: cstring){.header: "<stdio.h>", varargs.}
proc scanf(formatstr: cstring){.header: "<stdio.h>", varargs.}
var n :int32
scanf("%d\n",addr n)
var p = 0
for _ in 0..<n:
  var s:array[11,char]
  scanf("%s",addr s)
  for i in countdown(10,0):
    if s[i].ord < '0'.ord :continue
    if s[i].ord mod 2 == 0: p += 1
    else: p -= 1
    break
printf("%d\n",p.abs)
0