結果
問題 |
No.75 回数の期待値の問題
|
ユーザー |
![]() |
提出日時 | 2020-01-10 16:48:30 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
TLE
|
実行時間 | - |
コード長 | 332 bytes |
コンパイル時間 | 109 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 21,632 KB |
最終ジャッジ日時 | 2024-11-23 22:05:03 |
合計ジャッジ時間 | 35,249 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 12 TLE * 4 |
ソースコード
import sys sys.setrecursionlimit(10 ** 6) from random import randrange def II(): return int(sys.stdin.readline()) def main(): k = II() throw=0 turn=100000 for _ in range(turn): s=0 while s!=k: s+=randrange(1,7) throw+=1 if s>k:s=0 print(throw/turn) main()