#include <bits/stdc++.h>
using namespace std;
string cad;
void dfs(int i = 0) {
  if (i == cad.size()) return;
  if (cad[i] == 'r') cout << i + 1 << endl;
  dfs(i + 1);
  if (cad[i] == 'l') cout << i + 1 << endl;
}
int main() {
  while (cin >> cad) {
    dfs();
  }
  return 0;
}
