#include #define MAXN 100010 #define int long long using namespace std; using namespace chrono; int n, r, intersect[MAXN]; struct Point { long long x, y; int ind; bool IsIntersected(Point other) { long long lft = (other.x - x) * (other.x - x) + (other.y - y) * (other.y - y); long long rgt = 4 * r * r; return lft < rgt; } }arr[MAXN]; vector M[MAXN]; mt19937 mt(chrono::high_resolution_clock::now().time_since_epoch().count()); int myrng(int n) { return mt() % n; } signed main() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); freopen("mars.in", "r", stdin); freopen("mars.out", "w", stdout); auto bg = high_resolution_clock::now(); cin>>n>>r; for(int i = 0; i < n; i ++) { cin>>arr[i].x>>arr[i].y; arr[i].ind = i; } vector > ans; ans.push_back({1, 1}); while(duration_cast(high_resolution_clock::now() - bg).count() < 4500000) { random_shuffle(arr, arr + n, myrng); bool check = false; vector > cur; for(int i = 0; i < n; i ++) { check = false; for(int j = 0; j < cur.size(); j ++) { if(arr[i].IsIntersected(arr[cur[j].first])) { check = true; break; } } if(!check) cur.push_back({i, arr[i].ind}); } if(cur.size() > ans.size()) ans = cur; } cout<<(int)ans.size()<<'\n'; for(auto item : ans) cout<<(int)item.second + 1<<" "; cout<<"\n"; return 0; }