#include <bits/stdc++.h>
using namespace std;
int main() {
  string line;
  int a[1000001];
  cin >> line;
  int l = 0, r = line.size() - 1;
  for (int i = 0; i < line.size(); i++) {
    if (line[i] == 'l')
      a[r--] = i + 1;
    else
      a[l++] = i + 1;
  }
  for (int i = 0; i < line.size(); i++) cout << a[i] << "\n";
  return 0;
}
