from math import ceil

import re

S = input()

N = len(S)



X = re.findall('R+L+', S)

ans = [0] * N



i = 0

for x in X:

    x_len = len(x)

    start = x.find('RL')



    ans[i + start] += (x_len - start - 1) // 2 + ceil((start + 1) / 2)

    ans[i + start + 1] += (start + 1) // 2 + ceil((x_len - start - 1) / 2)



    i += x_len



print(*ans, sep=' ')

S = input()

N = len(S)



ans = [0] * N



cnt = 0

for i, s in enumerate(S):

    if s == 'R':

        cnt += 1

    else:

        ans[i] += cnt // 2

        ans[i - 1] += (cnt + 1) // 2

        cnt = 0



cnt = 0

ans = ans[::-1]



for i, s in enumerate(S[::-1]):

    if s == 'L':

        cnt += 1

    else:

        ans[i] += cnt // 2

        ans[i - 1] += (cnt + 1) // 2

        cnt = 0



print(*ans[::-1], sep=' ')

from math import ceil
import re

S = input()
N = len(S)
X = re.findall("R+L+", S)
ans = [0] * N
i = 0
for x in X:
    x_len = len(x)
    start = x.find("RL")
    ans[i + start] += (x_len - start - 1) // 2 + ceil((start + 1) / 2)
    ans[i + start + 1] += (start + 1) // 2 + ceil((x_len - start - 1) / 2)
    i += x_len
print(*ans, sep=" ")

S = input()
N = len(S)
ans = [0] * N
cnt = 0
for i, s in enumerate(S):
    if s == "R":
        cnt += 1
    else:
        ans[i] += cnt // 2
        ans[i - 1] += (cnt + 1) // 2
        cnt = 0
cnt = 0
ans = ans[::-1]
for i, s in enumerate(S[::-1]):
    if s == "L":
        cnt += 1
    else:
        ans[i] += cnt // 2
        ans[i - 1] += (cnt + 1) // 2
        cnt = 0
print(*ans[::-1], sep=" ")

-from math import ceil -import re - -X = re.findall("R+L+", S) -i = 0 -for x in X: -    x_len = len(x) -    start = x.find("RL") -    ans[i + start] += (x_len - start - 1) // 2 + ceil((start + 1) / 2) -    ans[i + start + 1] += (start + 1) // 2 + ceil((x_len - start - 1) / 2) -    i += x_len -print(*ans, sep=" ") +cnt = 0 +for i, s in enumerate(S): +    if s == "R": +        cnt += 1 +    else: +        ans[i] += cnt // 2 +        ans[i - 1] += (cnt + 1) // 2 +        cnt = 0 +cnt = 0 +ans = ans[::-1] +for i, s in enumerate(S[::-1]): +    if s == "L": +        cnt += 1 +    else: +        ans[i] += cnt // 2 +        ans[i - 1] += (cnt + 1) // 2 +        cnt = 0 +print(*ans[::-1], sep=" ")