Problem: A new bus route is opened in the city <image>. The route is a closed polygon line in the place, with all segments parallel to one of the axes. m buses will operate on the route. All buses move in a loop along the route in the same direction with equal constant velocities (stopping times are negligible in this problem).

Buses start their movement in the first vertex of the route with equal interval. Suppose that T is the total time for a single bus to travel the whole loop of the route. Then, the bus 1 starts moving at time 0, the bus 2 starts at time T / m, the bus 3 starts at time 2T / m, and so on; finally, the bus m starts moving at time (m - 1)T / m. Thus, all intervals between pairs of consecutive buses (including the interval between the last and the first bus) are equal.

Buses can communicate with each other via wireless transmitters of equal power. If the transmitters have power D, then only buses within distance D of each other can communicate.

The buses are also equipped with a distributed system of schedule tracking. For all buses to stick to the schedule, the system has to synchronize the necessary data between all buses from time to time. At the moment of synchronization, the bus 1 communicates with the bus 2, the bus 2 — with bus 3, and so on; also, the bus m communicates with the bus 1.

As a research employee, you are tasked with finding the smallest value of D such that it is possible to find a time moment to perform synchronization once all buses have started moving. 

Input

The first line contains two integers n and m (2 ≤ n, m ≤ 105) — the number of vertices of the polygonal line, and the number of buses respectively.

Next n lines describe the vertices of the route in the traversing order. Each of these lines contains two integers xi, yi ( - 1000 ≤ xi, yi ≤ 1000) — coordinates of respective vertex.

It is guaranteed that each leg of the route (including the leg between the last and the first vertex) is paralles to one of the coordinate axes. Moreover, no two subsequent vertices of the route coincide. The route is allowed to have self-intersections, and travel along the same segment multiple times.

Output

Print one real number — the answer to the problem. Your answer will be accepted if the relative or the absolute error doesn't exceed 10 - 6.

Examples

Input

4 2
0 0
0 1
1 1
1 0


Output

1.000000000


Input

2 2
0 0
1 0


Output

0.000000000

Note

Suppose that each bus travel 1 distance unit per second.

In the first sample case, in 0.5 seconds buses will be at distance 1, hence we can choose D = 1.

In the second sample case, in 0.5 seconds both buses will be at (0.5, 0), hence we can choose D = 0.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const long double EPS = 1e-10;
const int N = 110000;
const int M = 10 * N;
int n, m;
long double x[N], y[N], l[N];
long double dx[N], dy[N];
struct seg {
  long double from, to;
  long double x1, y1, x2, y2, dx1, dy1, dx2, dy2;
  seg() {}
  seg(long double from, long double to, long double x1, long double y1,
      long double x2, long double y2, long double dx1, long double dy1,
      long double dx2, long double dy2)
      : from(from),
        to(to),
        x1(x1),
        y1(y1),
        x2(x2),
        y2(y2),
        dx1(dx1),
        dy1(dy1),
        dx2(dx2),
        dy2(dy2) {}
  pair<long double, long double> getSeg(long double v) {
    long double a = x1 - x2, b = dx1 - dx2, c = y1 - y2, d = dy1 - dy2;
    long double A = ((b) * (b)) + ((d) * (d)), B = 2 * (a * b + c * d),
                C = ((a) * (a)) + ((c) * (c)) - ((v) * (v));
    if (fabs(A) < 1e-8) {
      if (C < 0) return make_pair(from, to);
      return make_pair(-1.0, -1.0);
    }
    long double D = ((B) * (B)) - 4 * A * C;
    if (D < 0) return make_pair(-1.0, -1.0);
    long double t1 = (-B - sqrt(D)) / (A * 2);
    long double t2 = (-B + sqrt(D)) / (A * 2);
    t1 = max(t1, (long double)0.0);
    t2 = min(t2, to - from);
    if (t2 < t1) return make_pair(-1.0, -1.0);
    return make_pair(t1 + from, t2 + from);
  }
};
long double len, d;
vector<seg> vec;
vector<pair<long double, long double>> tmp, ins;
vector<long double> pts;
int b[M];
bool can(long double md) {
  tmp.clear();
  for (auto &t : vec) {
    auto ret = t.getSeg(md);
    if (ret.first > -EPS) tmp.push_back(ret);
  }
  pts.clear();
  pts.push_back(0);
  pts.push_back(d);
  for (auto &t : tmp) {
    long double a[] = {t.first, t.second};
    for (int i = 0; i < 2; i++) {
      long double p = a[i] - d * floor(a[i] / d);
      pts.push_back(p);
    }
  }
  sort(pts.begin(), pts.end());
  assert(pts.size() < M);
  ins.clear();
  for (auto &_t : tmp) {
    long double from = _t.first, to = _t.second;
    int f = round(floor(from / d)), t = round(floor(to / d));
    if (f == t)
      ins.emplace_back(from - d * f, to - d * f);
    else {
      ins.emplace_back(from - d * f, d);
      if (f + 1 < t)
        for (int i = f; i < t - 1; i++) ins.emplace_back(0, d);
      ins.emplace_back(0, to - d * t);
    }
  }
  memset(b, 0, sizeof b);
  for (auto &t : ins) {
    int fid = lower_bound(pts.begin(), pts.end(), t.first - EPS) - pts.begin();
    int tid = lower_bound(pts.begin(), pts.end(), t.second - EPS) - pts.begin();
    b[fid]++;
    b[tid]--;
  }
  for (int i = 1; i < M; i++) b[i] += b[i - 1];
  for (int i = 0; i < M; i++)
    if (b[i] == m) return 1;
  return 0;
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; i++) {
    double _x, _y;
    scanf("%lf%lf", &_x, &_y);
    x[i] = _x;
    y[i] = _y;
  }
  x[n] = x[0], y[n] = y[0];
  len = 0;
  for (int i = 0; i < n; i++) {
    l[i] = sqrt(((x[i + 1] - x[i]) * (x[i + 1] - x[i])) +
                ((y[i + 1] - y[i]) * (y[i + 1] - y[i])));
    dx[i] = (x[i + 1] - x[i]) / l[i];
    dy[i] = (y[i + 1] - y[i]) / l[i];
    len += l[i];
  }
  d = len / m;
  int id1 = 0, id2 = 0;
  long double rest1 = l[0], rest2 = l[0];
  long double x1 = x[0], y1 = y[0], dx1 = dx[0], dy1 = dy[0];
  long double x2 = x[0], y2 = y[0], dx2 = dx[0], dy2 = dy[0];
  long double rest = d;
  while (1) {
    if (rest > l[id2]) {
      rest -= l[id2];
      id2 = (id2 + 1) % n;
      rest2 = l[id2];
      x2 = x[id2], y2 = y[id2], dx2 = dx[id2], dy2 = dy[id2];
      continue;
    }
    rest2 = l[id2] - rest;
    x2 += dx[id2] * rest;
    y2 += dy[id2] * rest;
    break;
  }
  long double cur = 0;
  while (1) {
    rest = min(rest1, rest2);
    if (fabs(rest) > EPS)
      vec.push_back(seg(cur, cur + rest, x1, y1, x2, y2, dx1, dy1, dx2, dy2));
    rest1 -= rest;
    rest2 -= rest;
    if (fabs(rest1) < EPS)
      id1 = (id1 + 1) % n, rest1 = l[id1], x1 = x[id1], y1 = y[id1],
      dx1 = dx[id1], dy1 = dy[id1];
    else
      x1 += dx1 * rest, y1 += dy1 * rest;
    if (fabs(rest2) < EPS)
      id2 = (id2 + 1) % n, rest2 = l[id2], x2 = x[id2], y2 = y[id2],
      dx2 = dx[id2], dy2 = dy[id2];
    else
      x2 += dx2 * rest, y2 += dy2 * rest;
    cur += rest;
    if (fabs(cur - len) < EPS) break;
  }
  long double st = 0, en = 4000;
  for (int times = 0; times < 50; times++) {
    long double md = (st + en) / 2;
    if (can(md))
      en = md;
    else
      st = md;
  }
  printf("%.10lf\n", (double)st);
}