#include <bits/stdc++.h>
using namespace std;
struct Pos {
  int n;
  vector<int> v;
  int c;
};
int main() {
  int n;
  cin >> n;
  Pos a[n];
  map<int, int> g;
  map<int, int> t;
  for (int i = 0; i < n; i++) {
    cin >> a[i].n;
    a[i].c = 0;
    for (int j = 0; j < a[i].n; j++) {
      int y;
      cin >> y;
      a[i].v.push_back(y);
      a[i].c += y;
    }
    for (int j = 0; j < a[i].n; j++) {
      if (g.count(a[i].c - a[i].v[j]) && g[a[i].c - a[i].v[j]] != i) {
        cout << "YES" << endl;
        cout << i + 1 << " " << j + 1 << endl;
        cout << g[a[i].c - a[i].v[j]] + 1 << " " << t[a[i].c - a[i].v[j]] + 1
             << endl;
        return 0;
      }
      g[a[i].c - a[i].v[j]] = i;
      t[a[i].c - a[i].v[j]] = j;
    }
  }
  cout << "NO";
}
