結果

問題 No.1132 凸凹
ユーザー 👑 KazunKazun
提出日時 2020-07-29 02:21:31
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 79 ms / 2,000 ms
コード長 229 bytes
コンパイル時間 394 ms
コンパイル使用メモリ 86,900 KB
実行使用メモリ 71,248 KB
最終ジャッジ日時 2023-09-11 07:02:24
合計ジャッジ時間 3,724 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
70,736 KB
testcase_01 AC 76 ms
70,684 KB
testcase_02 AC 77 ms
70,896 KB
testcase_03 AC 76 ms
70,684 KB
testcase_04 AC 76 ms
70,984 KB
testcase_05 AC 76 ms
70,684 KB
testcase_06 AC 76 ms
70,740 KB
testcase_07 AC 76 ms
71,244 KB
testcase_08 AC 77 ms
70,684 KB
testcase_09 AC 76 ms
71,048 KB
testcase_10 AC 77 ms
71,092 KB
testcase_11 AC 76 ms
70,972 KB
testcase_12 AC 76 ms
70,972 KB
testcase_13 AC 77 ms
71,248 KB
testcase_14 AC 76 ms
70,852 KB
testcase_15 AC 76 ms
71,020 KB
testcase_16 AC 75 ms
70,964 KB
testcase_17 AC 75 ms
71,032 KB
testcase_18 AC 76 ms
71,044 KB
testcase_19 AC 75 ms
70,916 KB
testcase_20 AC 77 ms
70,980 KB
testcase_21 AC 77 ms
71,244 KB
testcase_22 AC 77 ms
70,984 KB
testcase_23 AC 77 ms
70,840 KB
testcase_24 AC 79 ms
71,100 KB
testcase_25 AC 77 ms
70,964 KB
testcase_26 AC 77 ms
71,088 KB
testcase_27 AC 76 ms
70,752 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a,b,c,d,p,q=map(int,input().split())
f=lambda x:a*x*x*x+b*x*x+c*x+d

inf=float("inf")
M=inf
N=-inf

X,Y=0,0
for x in range(p,q+1):
    h=f(x)
    if h<M:
        X=x
        M=h
    if N<h:
        Y=x
        N=h
print(N,Y,M,X)
0