#include <bits/stdc++.h>
using namespace std;
int main() {
  int t, i;
  cin >> t;
  while (t--) {
    string s;
    cin >> s;
    int len = s.size();
    vector<int> ans;
    for (i = 0; i < len - 2; i++) {
      if (s[i] == 'o' && s[i + 1] == 'n' && s[i + 2] == 'e') {
        ans.push_back(i + 2);
        i += 1;
      }
      if (s[i] == 't' && s[i + 1] == 'w' && s[i + 2] == 'o') {
        if (s[i + 3] == 'n') {
          ans.push_back(i + 3);
          i += 2;
        } else {
          ans.push_back(i + 2);
          i += 1;
        }
      }
    }
    cout << ans.size() << endl;
    for (i = 0; i < ans.size(); i++) {
      cout << ans[i] << " ";
    }
    cout << endl;
  }
  return 0;
}
