結果
| 問題 |
No.3252 Constrained Moving
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-09-05 21:26:15 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 100 ms / 2,000 ms |
| コード長 | 178 bytes |
| コンパイル時間 | 193 ms |
| コンパイル使用メモリ | 82,352 KB |
| 実行使用メモリ | 107,980 KB |
| 最終ジャッジ日時 | 2025-09-05 21:26:22 |
| 合計ジャッジ時間 | 4,392 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 30 |
ソースコード
N,S,T,K=map(int,input().split())
A=list(map(int,input().split()))
if A[S-1]+A[T-1]<=K:
print(1)
elif A[S-1]+min(A)<=K and A[T-1]+min(A)<=K:
print(2)
else:
print(-1)