結果

問題 No.1330 Multiply or Divide
ユーザー aqua_tenhouaqua_tenhou
提出日時 2021-01-08 21:33:41
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 338 bytes
コンパイル時間 140 ms
コンパイル使用メモリ 82,176 KB
実行使用メモリ 102,912 KB
最終ジャッジ日時 2024-04-28 02:14:24
合計ジャッジ時間 4,675 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 39 ms
51,712 KB
testcase_03 AC 39 ms
51,456 KB
testcase_04 WA -
testcase_05 AC 35 ms
51,840 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 101 ms
102,144 KB
testcase_09 AC 97 ms
101,504 KB
testcase_10 AC 99 ms
101,760 KB
testcase_11 AC 99 ms
102,016 KB
testcase_12 AC 101 ms
101,632 KB
testcase_13 AC 35 ms
51,968 KB
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 35 ms
51,328 KB
testcase_17 WA -
testcase_18 AC 104 ms
101,888 KB
testcase_19 AC 99 ms
101,632 KB
testcase_20 AC 104 ms
101,760 KB
testcase_21 AC 106 ms
101,888 KB
testcase_22 AC 102 ms
101,888 KB
testcase_23 WA -
testcase_24 AC 37 ms
51,840 KB
testcase_25 AC 36 ms
51,968 KB
testcase_26 WA -
testcase_27 AC 36 ms
51,968 KB
testcase_28 AC 37 ms
51,456 KB
testcase_29 AC 36 ms
51,584 KB
testcase_30 AC 36 ms
51,584 KB
testcase_31 AC 34 ms
51,328 KB
testcase_32 AC 34 ms
51,584 KB
testcase_33 AC 34 ms
51,456 KB
testcase_34 AC 79 ms
96,640 KB
testcase_35 AC 51 ms
69,120 KB
testcase_36 AC 75 ms
92,928 KB
testcase_37 AC 72 ms
89,344 KB
testcase_38 AC 60 ms
78,080 KB
testcase_39 AC 54 ms
71,296 KB
testcase_40 AC 58 ms
74,240 KB
testcase_41 AC 49 ms
66,432 KB
testcase_42 AC 68 ms
86,528 KB
testcase_43 AC 73 ms
89,728 KB
testcase_44 WA -
testcase_45 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

n,m,p = map(int,input().split())
a = list(map(int,input().split()))
m_a = max(a)

s = -1
for x in a:
    if x//p == 0:
        pass
    else:
        s = max(s, x)
if s == -1:
    if m_a > m:
        print(1)
    else:
        print(-1)
else:
    ans = 1
    x = 1
    while x*m_a < m:
        x *= s
        ans += 1
    print(ans)
    
0