#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k, x = 100, q = 0, z;
  cin >> n >> m >> k;
  int arr[n];
  for (int i = 0; i < n; i++) {
    int p;
    cin >> p;
    arr[i] = p;
    if (arr[i] > 0 && arr[i] <= k && abs(m - (i + 1)) < x) {
      z = q + 1;
      x = abs(m - (i + 1));
    }
    if (p != 0) q++;
  }
  cout << x * 10 << endl;
}
