#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  int a[n];
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++) {
    if (a[i] > 0 and a[i] <= k) {
      a[i] = (i - m + 1) * 10;
      if (a[i] < 0) a[i] = -1 * a[i];
    } else
      a[i] = -1;
  }
  sort(a, a + n);
  for (int i = 0; i < n; i++) {
    if (a[i] > 0) {
      cout << a[i] << " ";
      break;
    }
  }
}
