#include <bits/stdc++.h>
using namespace std;
const int maxk = 2e5 + 5;
const int inf = 0x3f3f3f3f;
int k, m;
int main() {
  scanf("%d", &k);
  map<int, pair<int, int> > p;
  for (int i = 0; i < (k); i++) {
    scanf("%d", &m);
    int sum = 0;
    vector<int> t(m);
    for (int j = 0; j < (m); j++) {
      scanf("%d", &t[j]);
      sum += t[j];
    }
    for (int j = 0; j < (m); j++) {
      map<int, pair<int, int> >::iterator it = p.find(sum - t[j]);
      if (it == p.end())
        p.insert(pair<int, pair<int, int> >(sum - t[j], pair<int, int>(i, j)));
      else {
        if (it->second.first != i) {
          printf("YES\n%d %d\n%d %d\n", it->second.first + 1,
                 it->second.second + 1, i + 1, j + 1);
          return 0;
        }
      }
    }
  }
  puts("NO");
  return 0;
}
