#include <bits/stdc++.h>
using namespace std;
char s[150010];
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    getchar();
    memset(s, 0, sizeof(s));
    cin >> s;
    int len = strlen(s);
    int r = 0;
    int ans[150010];
    for (int i = 0; i < len; i++) {
      if (s[i] == 't') {
        if (s[i + 1] == 'w' && s[i + 2] == 'o') {
          if (s[i + 3] == 'n' && s[i + 4] == 'e') {
            ans[++r] = i + 3;
            i += 4;
          } else {
            ans[++r] = i + 2;
            i += 2;
          }
        }
      }
      if (s[i] == 'o') {
        if (s[i + 1] == 'n' && s[i + 2] == 'e') {
          ans[++r] = i + 2;
          i += 2;
        }
      }
    }
    printf("%d\n", r);
    for (int i = 1; i <= r; i++) {
      printf("%d%c", ans[i], i == r ? '\n' : ' ');
    }
  }
  return 0;
}
