S = eval(input())

N = len(S)



arr = [0] * N

cnt = 0



R = 0

res = -1

for i in range(N-1):

    if S[i] == "R":

        R += 1

        res += 1

    if S[i+1] == "L":

        arr[i+1] += R // 2

        arr[i] += -(-R // 2)

        R = 0

        cnt = max(cnt, res)

        res = -1



L = 0

res = -1



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

    if S[i] == "L":

        L += 1

        res += 1

    if S[i-1] == "R":

        arr[i-1] += L // 2

        arr[i] += -(-L // 2)

        L = 0

        cnt = max(cnt, res)

        res = -1



print((*arr))
S = eval(input())

N = len(S)



arr = [0] * N



R = 0

for i in range(N-1):

    if S[i] == "R":

        R += 1

    if S[i+1] == "L":

        arr[i+1] += R // 2

        arr[i] += -(-R // 2)

        R = 0



L = 0



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

    if S[i] == "L":

        L += 1

    if S[i-1] == "R":

        arr[i-1] += L // 2

        arr[i] += -(-L // 2)

        L = 0

    

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

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

-cnt = 0 -res = -1 -        res += 1 -        cnt = max(cnt, res) -        res = -1 -res = -1 -        res += 1 -        cnt = max(cnt, res) -        res = -1