//yukicoder 231 "めぐるはめぐる(1)" //http://yukicoder.me/problems/535 #include using namespace std; int n, g[1005], d[1005]; int main() { int maxid = 0; cin >> n; for (int i = 0; i < n; i++) { cin >> g[i] >> d[i]; } for (int i = 1; i < n; i++) { if (g[maxid] < g[i]) maxid = i; } if (6 * (g[maxid] - 30000 * d[maxid]) > 3000000) { cout << "YES" << endl; for (int i = 0; i < 6; i++) { cout << maxid + 1 << endl; } } else cout << "NO" << endl; return 0; }