S = list(eval(input()))

S.reverse()



c = [0 for _ in range(len(S))]

l_start_index = 0

l_end_index = -1

r_start_index = -1

r_end_index = -1



# def count():

#     s = r_end_index - l_start_index + 1

#     if s % 2 == 0:

#         c[l_end_index] = s // 2

#         c[r_start_index] = s // 2

#     else:

#         if l_end_index % 2 == 0:

#             c[l_end_index] = s // 2 + 1

#             c[r_start_index] = s // 2

#         else:

#             c[l_end_index] = s // 2

#             c[r_start_index] = s // 2 + 1





def count2():

    for i in range(l_start_index, r_end_index + 1):

        if (r_start_index - i) % 2 == 0:

            c[r_start_index] += 1

        else:

            c[l_end_index] += 1





for i in range(len(S) - 1):

    if S[i] == 'L' and S[i + 1] == 'R':

        l_end_index = i

        r_start_index = i + 1

    if S[i] == 'R' and S[i + 1] == 'L':

        r_end_index = i

        count2()

        l_start_index = i + 1

else:

    r_end_index = i + 1

    count2()



c.reverse()

for i in c:

    print(i)

LOG = 18  # log2(10**5)

S = eval(input())

N = len(S)

to = [[0] * N for _ in range(LOG)]



for i in range(N):

    to[0][i] = i + 1 if S[i] == 'R' else i - 1



for i in range(1, LOG):

    for j in range(N):

        to[i][j] = to[i - 1][to[i - 1][j]]



ans = [0] * N

for i in range(N):

    ans[to[LOG - 1][i]] += 1



L = [str(i) for i in ans]

print((' '.join(L)))

S = list(eval(input()))
S.reverse()
c = [0 for _ in range(len(S))]
l_start_index = 0
l_end_index = -1
r_start_index = -1
r_end_index = -1
# def count():
#     s = r_end_index - l_start_index + 1
#     if s % 2 == 0:
#         c[l_end_index] = s // 2
#         c[r_start_index] = s // 2
#     else:
#         if l_end_index % 2 == 0:
#             c[l_end_index] = s // 2 + 1
#             c[r_start_index] = s // 2
#         else:
#             c[l_end_index] = s // 2
#             c[r_start_index] = s // 2 + 1
def count2():
    for i in range(l_start_index, r_end_index + 1):
        if (r_start_index - i) % 2 == 0:
            c[r_start_index] += 1
        else:
            c[l_end_index] += 1


for i in range(len(S) - 1):
    if S[i] == "L" and S[i + 1] == "R":
        l_end_index = i
        r_start_index = i + 1
    if S[i] == "R" and S[i + 1] == "L":
        r_end_index = i
        count2()
        l_start_index = i + 1
else:
    r_end_index = i + 1
    count2()
c.reverse()
for i in c:
    print(i)

LOG = 18  # log2(10**5)
S = eval(input())
N = len(S)
to = [[0] * N for _ in range(LOG)]
for i in range(N):
    to[0][i] = i + 1 if S[i] == "R" else i - 1
for i in range(1, LOG):
    for j in range(N):
        to[i][j] = to[i - 1][to[i - 1][j]]
ans = [0] * N
for i in range(N):
    ans[to[LOG - 1][i]] += 1
L = [str(i) for i in ans]
print((" ".join(L)))

-S = list(eval(input())) -S.reverse() -c = [0 for _ in range(len(S))] -l_start_index = 0 -l_end_index = -1 -r_start_index = -1 -r_end_index = -1 -# def count(): -#     s = r_end_index - l_start_index + 1 -#     if s % 2 == 0: -#         c[l_end_index] = s // 2 -#         c[r_start_index] = s // 2 -#     else: -#         if l_end_index % 2 == 0: -#             c[l_end_index] = s // 2 + 1 -#             c[r_start_index] = s // 2 -#         else: -#             c[l_end_index] = s // 2 -#             c[r_start_index] = s // 2 + 1 -def count2(): -    for i in range(l_start_index, r_end_index + 1): -        if (r_start_index - i) % 2 == 0: -            c[r_start_index] += 1 -        else: -            c[l_end_index] += 1 - - -for i in range(len(S) - 1): -    if S[i] == "L" and S[i + 1] == "R": -        l_end_index = i -        r_start_index = i + 1 -    if S[i] == "R" and S[i + 1] == "L": -        r_end_index = i -        count2() -        l_start_index = i + 1 -else: -    r_end_index = i + 1 -    count2() -c.reverse() -for i in c: -    print(i) +LOG = 18  # log2(10**5) +S = eval(input()) +N = len(S) +to = [[0] * N for _ in range(LOG)] +for i in range(N): +    to[0][i] = i + 1 if S[i] == "R" else i - 1 +for i in range(1, LOG): +    for j in range(N): +        to[i][j] = to[i - 1][to[i - 1][j]] +ans = [0] * N +for i in range(N): +    ans[to[LOG - 1][i]] += 1 +L = [str(i) for i in ans] +print((" ".join(L)))