#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define MAX 1002 int n; long long int g[MAX]; long long int d[MAX]; long long int m[MAX]; #define want 30000LL int main(){ scanf("%d", &n); for (int i = 0; i < n; i++){ scanf("%lld%lld", &g[i], &d[i]); m[i] = g[i] - d[i] * 30000LL; if (m[i] < 0){ return 1; } } long long int maxt = INT_MIN; int ind = 0; for (int i = 0; i < n; i++){ if (maxt < m[i]){ maxt = m[i]; ind = i; } } if (maxt * 6LL >= want){ cout << "YES" << endl; for (int i = 0; i < 6; i++){ cout << ind + 1 << endl; } } else{ cout << "NO" << endl; } return 0; }