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