#include <bits/stdc++.h>
using namespace std;
int main() {
  int siz;
  int girl;
  int money;
  int ned;
  int count = 0;
  cin >> siz;
  cin >> girl;
  int cruch = girl - 1;
  cin >> money;
  if (money != 0 | siz > 2 | cruch < siz) {
    int arr[siz];
    for (int i = 0; i < siz; i++) {
      cin >> arr[i];
    }
    for (int i = 0; i < siz; i++) {
      if (money >= arr[i] && arr[i] != 0) {
        count++;
      }
    }
    int arr2[count];
    int j = 0;
    for (int i = 0; i < siz; i++) {
      if (money >= arr[i] && arr[i] != 0) {
        ned = abs((i)-cruch);
        arr2[j] = ned;
        j++;
      }
    }
    int small = arr2[0];
    for (int i = 0; i < count; i++) {
      if (small > arr2[i]) {
        small = arr2[i];
      }
    }
    cout << small * 10;
  } else
    return 0;
}
