結果

問題 No.2092 Conjugation
ユーザー tamato
提出日時 2022-10-07 21:23:03
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 80 ms / 2,000 ms
コード長 389 bytes
コンパイル時間 361 ms
コンパイル使用メモリ 82,304 KB
実行使用メモリ 95,104 KB
最終ジャッジ日時 2024-06-12 05:43:50
合計ジャッジ時間 2,421 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 18
権限があれば一括ダウンロードができます

ソースコード

diff #

mod = 998244353


def main():
    import sys
    input = sys.stdin.readline

    N = int(input())
    A = list(map(int, input().split()))

    M = A[0]
    ans = [0] * (M + 1)
    imos = [0] * (M + 2)
    for a in A:
        imos[1] += 1
        imos[a + 1] -= 1
    for i in range(1, M+1):
        ans[i] = ans[i - 1] + imos[i]
    print(*ans[1:])


if __name__ == '__main__':
    main()
0