#include <bits/stdc++.h>
using namespace std;
int n, x[1001], y[1001], k = 1001 * 1001;
set<int> s[4];
int lowbit(int x) { return x & (-x); }
int main() {
  scanf("%d%d%d", &n, &x[1], &y[1]);
  for (int i = 2; i <= n; i++) {
    scanf("%d%d", &x[i], &y[i]);
    x[i] -= x[1], y[i] -= y[1];
    if (x[i]) k = min(k, lowbit(x[i]));
    if (y[i]) k = min(k, lowbit(y[i]));
    x[i] = abs(x[i]), y[i] = abs(y[i]);
  }
  x[1] = y[1] = 0;
  for (int i = 1; i <= n; i++) {
    x[i] /= k, y[i] /= k;
    s[(x[i] & 1) * 2 + (y[i] & 1)].insert(i);
  }
  int ans = s[0].size();
  if (!s[1].empty() || !s[2].empty()) ans += s[3].size();
  printf("%d\n", ans);
  for (auto i : s[0]) printf("%d\n", i);
  if (!s[1].empty() || !s[2].empty())
    for (auto i : s[3]) printf("%d\n", i);
}
