#include using namespace std; using ll =long long; int main(){ ios::sync_with_stdio(false); cin.tie(nullptr); int N,S,T,K; cin>>N>>S>>T>>K; S--;T--; int m=1e9; vector A(N); for(int i=0;i>A[i]; m=min(m,A[i]); } if(A[S]+A[T]<=K){ cout<<1<<"\n"; } else if(A[S]+m<=K&&A[T]+m<=K)cout<<2<<"\n"; else cout<<-1<<"\n"; }