#define _CRT_SECURE_NO_WARNINGS #include #include #include #include #include #include #include #include #include #include #include #include //#include "util.h" using namespace std; typedef long long lint; typedef pair Pii; #define PI 3.14159265358979323846 #define EPS 1e-6 #define MOD ((lint)1000000007) #define MIN(a,b) ((a)<(b)?(a):(b)) #define MAX(a,b) ((a)>(b)?(a):(b)) int main() { bool flag = false; int N, G, D, ans; cin >> N; for (int i = 1; i <= N; i++) { cin >> G >> D; if ((G - 30000 * D) * 6 >= 3000000) { flag = true; ans = i; } } if (flag) { cout << "YES" << endl; for (int i = 0; i < 6; i++) { cout << ans << endl; } } else cout << "NO" << endl; return 0; }