#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n;
  cin >> n;
  map<int, vector<pair<int, int>>> m;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    vector<int> v(x);
    map<int, pair<int, int>> m1;
    int sum = 0;
    for (int j = 0; j < x; j++) cin >> v[j], sum += v[j];
    for (int j = 0; j < x; j++) {
      m1[sum - v[j]] = {i + 1, j + 1};
    }
    for (auto it : m1) {
      m[it.first].push_back(it.second);
    }
  }
  for (auto it : m) {
    if (m[it.first].size() >= 2) {
      cout << "YES\n";
      for (int i = 0; i < 2; i++) {
        cout << m[it.first][i].first << " " << m[it.first][i].second << "\n";
      }
      return 0;
    }
  }
  cout << "NO\n";
}
