#include <bits/stdc++.h>
using namespace std;
long long modularExponentiation(long long x, long long n, long long mm) {
  long long result = 1;
  while (n > 0) {
    if (n % 2 == 1) result = (result * x) % mm;
    x = (x * x) % mm;
    n = n / 2;
  }
  return result;
}
long long fib(long long n) {
  long double phi = (1 + sqrt(5)) / 2;
  return round(pow(phi, n) / sqrt(5));
}
vector<bool> prime(100000, true);
void SieveOfEratosthenes() {
  prime[0] = false;
  prime[1] = false;
  for (long long p = 2; p * p <= prime.size(); p++) {
    if (prime[p] == true) {
      for (long long i = p * p; i <= prime.size(); i += p) prime[i] = false;
    }
  }
}
long long min(long long a, long long b) { return a < b ? a : b; }
void solve() {
  string s;
  cin >> s;
  s = s + "#########";
  vector<long long> index;
  for (long long i = 0; i < s.size(); i++) {
    if (s[i] == 'o' && s[i + 1] == 'n' && s[i + 2] == 'e') {
      index.push_back(i + 1);
      i += 2;
    } else if (s[i] == 't' && s[i + 1] == 'w' && s[i + 2] == 'o' &&
               s[i + 3] == 'n' && s[i + 4] == 'e') {
      index.push_back(i + 2);
      i += 4;
    } else if (s[i] == 't' && s[i + 1] == 'w' && s[i + 2] == 'o') {
      index.push_back(i + 1);
      i += 2;
    }
  }
  cout << index.size() << '\n';
  for (auto it : index) cout << it + 1 << " ";
  cout << '\n';
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long t = 1;
  cin >> t;
  while (t--) solve();
}
