#include <bits/stdc++.h>
using namespace std;
const int N = 1000;
char cc[N];
int aa[N];
int main() {
  int n;
  cin >> n >> cc;
  for (int i = 1, a = 1; i < n; i++)
    aa[i] = a = cc[i - 1] == 'L' ? 1 : (cc[i - 1] == 'R' ? a + 1 : a);
  for (int i = n - 2, a = 1; i >= 0; i--)
    aa[i] = max(aa[i], a = cc[i] == 'R' ? 1 : (cc[i] == 'L' ? a + 1 : a));
  for (int i = 0; i < n; i++) cout << aa[i] << ' ';
  cout << '\n';
  return 0;
}
