#include <bits/stdc++.h>
using namespace std;
void solve() {
  string s;
  cin >> s;
  char a = ' ', b = ' ';
  vector<int> ans;
  for (int i = 0; i < s.length(); i++) {
    if (a == 'o' && b == 'n' && s[i] == 'e') {
      if (i + 1 < s.length() && s[i + 1] == 'e') {
        ans.push_back(i);
        b = s[i];
      } else {
        ans.push_back(i + 1);
      }
    } else if (a == 't' && b == 'w' && s[i] == 'o') {
      if (i + 1 < s.length() && s[i + 1] == 'o') {
        ans.push_back(i);
        b = s[i];
      } else {
        ans.push_back(i + 1);
      }
    } else {
      a = b;
      b = s[i];
    }
  }
  cout << ans.size() << endl;
  for (int i = 0; i < ans.size(); i++) {
    cout << ans[i];
    if (i < ans.size() - 1) cout << " ";
  }
  cout << endl;
}
int main() {
  cin.tie(0);
  cout.tie(0);
  ios_base::sync_with_stdio(0);
  int t = 1;
  cin >> t;
  while (t > 0) {
    t--;
    solve();
  }
  return 0;
}
