結果

問題 No.211 素数サイコロと合成数サイコロ (1)
ユーザー turner18_jp
提出日時 2017-12-08 20:26:49
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 455 bytes
コンパイル時間 83 ms
コンパイル使用メモリ 12,288 KB
実行使用メモリ 10,752 KB
最終ジャッジ日時 2024-11-29 19:43:34
合計ジャッジ時間 2,119 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 30 WA * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

k = int(input())
s = []
dice1 = [2, 3, 5, 7, 11, 13]
dice2 = [4, 6, 8, 9, 10, 12]

for i in dice1:
  count1 = 0
  count2 = 0
  for j in dice2:
    if j * i == k: 
      count2 += 1
      temp = j
  if count2 >= 1:
    for i in dice1:
      if i * temp == k:
        count1 += 1
  
  if count1 >= 1 and count2 >= 1:
    s.append(count1/6)
    s.append(count2/6)

if s == []:
  print(0)
else:
  p = s[0]
  for i in range(1, len(s)):
    p *= s[i]
  print(p)
0