結果
問題 | No.365 ジェンガソート |
ユーザー |
|
提出日時 | 2016-04-29 22:53:23 |
言語 | Python2 (2.7.18) |
結果 |
AC
|
実行時間 | 97 ms / 2,000 ms |
コード長 | 270 bytes |
コンパイル時間 | 77 ms |
コンパイル使用メモリ | 6,944 KB |
実行使用メモリ | 16,684 KB |
最終ジャッジ日時 | 2024-10-12 01:44:52 |
合計ジャッジ時間 | 3,927 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 41 |
ソースコード
# -*- coding: utf-8 -*-import sys,copy,math,heapq,itertools as it,fractions,re,bisect,collections as collN = int(raw_input())a = map(int, raw_input().split())ans = 0k = Nwhile a:x = a.pop()if x == k:k -= 1else:ans += 1print ans