結果

問題 No.58 イカサマなサイコロ
ユーザー fmhrfmhr
提出日時 2015-06-19 13:18:23
言語 PyPy2
(7.3.15)
結果
WA  
実行時間 -
コード長 221 bytes
コンパイル時間 2,043 ms
コンパイル使用メモリ 77,676 KB
実行使用メモリ 98,776 KB
最終ジャッジ日時 2023-09-21 09:45:40
合計ジャッジ時間 7,800 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import random
N=int(input())
K=int(input())
w=0
c=755000
a=random.randrange
r=range
for i in r(c):
	t=0
	j=0
	for _ in r(N):
		j+=a(1,7)
	for _ in r(K):
		t+=a(4,7)
	for _ in r(N-K):
		t+=a(1,7)
	if t>j:
		w+=1
print(w/c)
0