#!/bin/env ruby

s = STDIN.gets.chars
s.pop

before = Array.new(s.size, 1)
current = Array.new(s.size, 1)
after = Array.new(s.size, 0)

1.upto(10 ** 100) do |i|
  s.each_index do |j|
    if s[j] == 'R'
      after[j+1] = after[j+1] + current[j]
    elsif s[j] == 'L'
      after[j-1] = after[j-1] + current[j]
    end
  end
  break if after == current

  if before == after
    if i.odd?
      puts current.join(" ")
      exit
    else
      puts after.join(" ")
      exit
    end
  end
  before = current.dup
  current = after.dup
  after = Array.new(s.size, 0)
end

puts after.join(" ")
