#include <bits/stdc++.h>
using namespace std;
int seq[1000002];
int main() {
  int i, len, l, r;
  string input;
  cin >> input;
  len = input.size();
  l = len - 1;
  r = 0;
  for (i = 0; i < len; i++) {
    if (input[i] == 'l') {
      seq[l--] = i + 1;
    } else if (input[i] == 'r') {
      seq[r++] = i + 1;
    }
  }
  for (i = 0; i < len; i++) {
    cout << seq[i] << endl;
  }
  return 0;
}
