#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k, x, i = 1, d, dist = 0;
  cin >> n >> m >> k;
  vector<int> v;
  while (n--) {
    cin >> x;
    v.push_back(x);
    if (x != 0 && x <= k) {
      d = abs(m - i) * 10;
      if (dist == 0) {
        dist = d;
      } else if (d < dist) {
        dist = d;
      }
    }
    i++;
  }
  cout << dist;
  return 0;
}
