#include <bits/stdc++.h>
using namespace std;
struct node {
  int num;
  int value;
};
node a[1000060];
char s[1000060];
int cmp(node x, node y) { return x.value < y.value; }
int main() {
  scanf(" %s", s);
  int n = strlen(s);
  int l = 0, r = n - 1;
  for (int i = 0; i < n; i++) {
    a[i].num = i + 1;
    if (s[i] == 'l') {
      a[i].value = r;
      r--;
    }
    if (s[i] == 'r') {
      a[i].value = l;
      l++;
    }
  }
  sort(a, a + n, cmp);
  for (int i = 0; i < n; i++) printf("%d\n", a[i].num);
}
