#include using namespace std; using ll = long long; bool chmin(auto &a, auto b) { return a > b ? a = b, true : false; } bool chmax(auto &a, auto b) { return a < b ? a = b, true : false; } int main() { cin.tie(nullptr); ios::sync_with_stdio(false); int N, S, T, K; cin >> N >> S >> T >> K; --S, --T; vector> A(N); for(int i=0; i> A[i].first; A[i].second = i; } sort(A.begin(), A.end()); int s = -1, t = -1; for(int i=0; i