#include <bits/stdc++.h>
using namespace std;
string s;
int i, n, l[1000010], r[1000010];
int main() {
  cin >> s;
  n = s.length();
  for (i = 0; i < n; i++) {
    if (s[i] == 'l')
      l[++l[0]] = i + 1;
    else if (s[i] == 'r')
      r[++r[0]] = i + 1;
  }
  for (i = 1; i <= r[0]; i++) cout << r[i] << "\n";
  for (i = l[0]; i > 0; i--) cout << l[i] << "\n";
  return 0;
}
