#include <bits/stdc++.h>
using namespace std;
const int maxn = 1000 + 15;
int n, K, x[maxn], y[maxn], dis[maxn][maxn], del[maxn], deg[maxn];
vector<int> G[maxn], Consider, que;
bool Dfs(int df, int cur) {
  if (df < 0) return false;
  if (cur == Consider.size()) return true;
  if (del[Consider[cur]]) return Dfs(df, cur + 1);
  int have = 0;
  for (auto&& v : G[Consider[cur]])
    if (!del[v] && (++have) > 1) break;
  if (have) {
    if (have > 1) {
      del[Consider[cur]] = 1;
      if (Dfs(df - 1, cur + 1)) return true;
      del[Consider[cur]] = 0;
    }
    vector<int> Rolback;
    for (auto&& v : G[Consider[cur]])
      if (!del[v]) {
        Rolback.emplace_back(v);
        del[v] = 1;
      }
    if (Dfs(df - (int)Rolback.size(), cur + 1)) return true;
    for (auto&& it : Rolback) del[it] = 0;
    return false;
  }
  return Dfs(df, cur + 1);
}
bool Check(int limit) {
  Consider.clear();
  que.clear();
  memset(deg, 0, n << 2);
  memset(del, 0, n << 2);
  for (int i = 0; i < n; ++i) G[i].clear();
  int df = K;
  for (int i = 0; i < n; ++i) {
    for (int j = 0; j < n; ++j)
      if (dis[i][j] > limit && !del[j]) ++deg[i];
    if (deg[i] > df) del[i] = 1, --df;
  }
  if (df < 0) return false;
  memset(deg, 0, n << 2);
  for (int i = 0; i < n; ++i) {
    if (del[i]) continue;
    for (int j = 0; j < n; ++j)
      if (dis[i][j] > limit && !del[j]) ++deg[i];
    if (deg[i] == 1) que.emplace_back(i);
  }
  while (!que.empty()) {
    int x = que.back(), y = -1;
    que.pop_back();
    if (del[x]) continue;
    for (int j = 0; j < n; ++j)
      if (dis[x][j] > limit && !del[j]) {
        y = j;
        break;
      }
    if (y == -1) continue;
    --df;
    del[y] = 1;
    for (int j = 0; j < n; ++j)
      if (!del[j] && dis[j][y] > limit) {
        --deg[j];
        if (deg[j] == 1) que.emplace_back(j);
      }
  }
  if (df < 0) return false;
  memset(deg, 0, n << 2);
  for (int i = 0; i < n; ++i) {
    if (del[i]) continue;
    for (int j = 0; j < n; ++j)
      if (!del[j] && dis[i][j] > limit) ++deg[i], G[i].emplace_back(j);
    if (!deg[i]) continue;
    assert(deg[i] > 1 && deg[i] <= K);
    Consider.emplace_back(i);
  }
  sort(Consider.begin(), Consider.end(),
       [&](const int& x, const int& y) { return deg[x] > deg[y]; });
  return Dfs(df, 0);
}
int main(int argc, char* argv[]) {
  scanf("%d%d", &n, &K);
  for (int i = 0; i < n; ++i) scanf("%d%d", x + i, y + i);
  for (int i = 0; i < n; ++i)
    for (int j = 0; j < n; ++j)
      dis[i][j] = (x[i] - x[j]) * (x[i] - x[j]) + (y[i] - y[j]) * (y[i] - y[j]);
  int l = 0, r = 2048000000;
  while (l < r) {
    int mid = l + ((r - l) >> 1);
    if (Check(mid))
      r = mid;
    else
      l = mid + 1;
  }
  Check(l);
  vector<int> ans;
  int pf = K;
  for (int i = 0; i < n; ++i)
    if (del[i]) ans.emplace_back(i), --pf;
  for (int i = 0; i < n && pf; ++i)
    if (!del[i]) ans.emplace_back(i), --pf;
  for (auto&& x : ans) printf("%d ", x + 1);
  puts("");
  return 0;
}
