S = eval(input())

N = len(S)

ans = [0]*N



cnt = 0

for i in range(N) :

    if S[i] == "R" :

        cnt += 1



    elif cnt % 2 == 0 :

        ans[i] += cnt//2

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

        cnt = 0

    else :

        ans[i] += cnt//2

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

        cnt = 0

cnt = 0

for i in range(N-1,-1,-1) :

    if S[i] == "L" :

        cnt += 1

    

    elif cnt % 2 == 0 :

        ans[i] += cnt//2

        ans[i+1] += cnt//2

        cnt = 0

    else :

        ans[i] += cnt//2

        ans[i+1] += cnt//2 + 1

        cnt = 0

print((*ans))

S = eval(input())

N = len(S)



A = [0 for i in range(N)]



c = 0

for i in range(N) :

    if S[i] == "R" :

        c += 1

    else :

        if c % 2 == 0 :

            A[i] += c//2

            A[i-1] += c//2

        else :

            A[i] += c//2

            A[i-1] += c//2 + 1

        c = 0



c = 0

for i in range(N-1,-1,-1) :

    if S[i] == "L" :

        c += 1

    else :

        if c % 2 == 0 :

            A[i] += c//2

            A[i+1] += c//2

        else :

            A[i] += c//2

            A[i+1] += c//2 + 1

        c = 0

print((*A))

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

S = eval(input())
N = len(S)
A = [0 for i in range(N)]
c = 0
for i in range(N):
    if S[i] == "R":
        c += 1
    else:
        if c % 2 == 0:
            A[i] += c // 2
            A[i - 1] += c // 2
        else:
            A[i] += c // 2
            A[i - 1] += c // 2 + 1
        c = 0
c = 0
for i in range(N - 1, -1, -1):
    if S[i] == "L":
        c += 1
    else:
        if c % 2 == 0:
            A[i] += c // 2
            A[i + 1] += c // 2
        else:
            A[i] += c // 2
            A[i + 1] += c // 2 + 1
        c = 0
print((*A))

-ans = [0] * N -cnt = 0 +A = [0 for i in range(N)] +c = 0 -        cnt += 1 -    elif cnt % 2 == 0: -        ans[i] += cnt // 2 -        ans[i - 1] += cnt // 2 -        cnt = 0 +        c += 1 -        ans[i] += cnt // 2 -        ans[i - 1] += cnt // 2 + 1 -        cnt = 0 -cnt = 0 +        if c % 2 == 0: +            A[i] += c // 2 +            A[i - 1] += c // 2 +        else: +            A[i] += c // 2 +            A[i - 1] += c // 2 + 1 +        c = 0 +c = 0 -        cnt += 1 -    elif cnt % 2 == 0: -        ans[i] += cnt // 2 -        ans[i + 1] += cnt // 2 -        cnt = 0 +        c += 1 -        ans[i] += cnt // 2 -        ans[i + 1] += cnt // 2 + 1 -        cnt = 0 -print((*ans)) +        if c % 2 == 0: +            A[i] += c // 2 +            A[i + 1] += c // 2 +        else: +            A[i] += c // 2 +            A[i + 1] += c // 2 + 1 +        c = 0 +print((*A))