結果

問題 No.65 回数の期待値の練習
ユーザー cologne
提出日時 2022-01-25 01:15:42
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 36 ms / 5,000 ms
コード長 240 bytes
コンパイル時間 639 ms
コンパイル使用メモリ 82,444 KB
実行使用メモリ 54,156 KB
最終ジャッジ日時 2024-12-15 05:58:27
合計ジャッジ時間 2,128 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys


def input(): return sys.stdin.readline().rstrip()


def main():
    K = int(input())

    A = [0, 0, 0, 0, 0, 0]
    for i in range(K):
        A = A[1:] + [sum(A)/6+1]

    print(A[-1])


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