#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 5;
int num[maxn];
long long sum[maxn];
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> num[i], num[i + n] = num[i];
  for (int i = 1; i <= 2 * n; i++) sum[i] = sum[i - 1] + num[i];
  int s, f;
  cin >> s >> f;
  f--;
  long long mx = -1;
  int id;
  for (int i = 1; i <= n; i++) {
    long long temp = sum[n - i + 1 + f] - sum[n - i + 1 + s - 1];
    if (temp > mx) {
      mx = temp;
      id = i;
    }
  }
  cout << id << "\n";
  return 0;
}
