#include <bits/stdc++.h>
using namespace std;
inline int input() {
  int n;
  cin >> n;
  return n;
}
long long pw(long long a, long long b) {
  return (!b ? 1 : (b & 1 ? a * pw(a * a, b / 2) : pw(a * a, b / 2)));
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  string s;
  cin >> s;
  deque<int> q;
  for (int i = s.size() - 1; i >= 0; i--) {
    if (s[i] == 'l') q.push_back(i + 1);
    if (s[i] == 'r') q.push_front(i + 1);
  }
  for (int i = 0; i < s.size(); i++) cout << q[i] << endl;
  return 0;
}
