#include <bits/stdc++.h>
using namespace std;
char s[1000005];
int ans[1000005];
int main() {
  cin >> s;
  int len = strlen(s);
  int i, j;
  int l = 1, r = len;
  for (i = 1; i <= len; i++) {
    if (s[i - 1] == 'l')
      ans[r--] = i;
    else
      ans[l++] = i;
  }
  for (i = 1; i <= len; i++) printf("%d\n", ans[i]);
}
