#include <bits/stdc++.h>
using namespace std;
int main() {
  int res = 9999999, k, m, n;
  cin >> n >> m >> k;
  vector<int> a(n);
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] <= k && a[i] != 0) {
      if (abs(i + 1 - m) < res) res = abs(i + 1 - m);
    }
  }
  cout << res * 10;
}
