#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const int N = 1e5 + 20;
const double eps = 1e-8;
int main() {
  int n, m, k;
  while (cin >> n >> m >> k) {
    int mi = INF;
    for (int i = 1; i <= n; i++) {
      int x;
      scanf("%d", &x);
      if (x <= k && x != 0) mi = min(mi, abs(i - m));
    }
    printf("%d\n", mi * 10);
  }
  return 0;
}
