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