

S = eval(input())

n = len(S)

ans = [0 for i in range(n)]

for i in range(n):

    if S[i:i+2] == "RL":

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

            if S[j] == "R":

                ans[i + (i-j) % 2] += 1

            else:

                break

        for j in range(i+1,n):

            if S[j] == "L":

                ans[i + (j-i) % 2] += 1

            else:

                break



print((*ans))
def main():

    S = eval(input())

    N = len(S)

    idx = 0

    cur = 1

    pre = S[0]

    ans = [0]*N

    for i in range(1, N):

        #print(i, idx, cur, ans)

        if pre == S[i] == "R":

            idx += 1

            cur += 1

        elif pre == S[i] == "L":

            cur += 1

        elif pre != S[i] == "R":

            if 0 <= idx - 1:

                ans[idx-1] += cur // 2

                ans[idx] += (cur + 1)//2

            else:

                ans[idx] += cur

            idx = i

            cur = 1

        elif pre != S[i] == "L":

            ans[idx] += (cur + 1)//2

            ans[idx + 1] += cur // 2

            idx = i

            cur = 1

        pre = S[i]

    if pre == "L":

        ans[idx] += (cur+1)//2

        ans[idx-1] += cur//2

    else:

        ans[idx] += cur

    print((*ans))





if __name__ == '__main__':

    main()

S = eval(input())
n = len(S)
ans = [0 for i in range(n)]
for i in range(n):
    if S[i : i + 2] == "RL":
        for j in range(i, -1, -1):
            if S[j] == "R":
                ans[i + (i - j) % 2] += 1
            else:
                break
        for j in range(i + 1, n):
            if S[j] == "L":
                ans[i + (j - i) % 2] += 1
            else:
                break
print((*ans))

def main():
    S = eval(input())
    N = len(S)
    idx = 0
    cur = 1
    pre = S[0]
    ans = [0] * N
    for i in range(1, N):
        # print(i, idx, cur, ans)
        if pre == S[i] == "R":
            idx += 1
            cur += 1
        elif pre == S[i] == "L":
            cur += 1
        elif pre != S[i] == "R":
            if 0 <= idx - 1:
                ans[idx - 1] += cur // 2
                ans[idx] += (cur + 1) // 2
            else:
                ans[idx] += cur
            idx = i
            cur = 1
        elif pre != S[i] == "L":
            ans[idx] += (cur + 1) // 2
            ans[idx + 1] += cur // 2
            idx = i
            cur = 1
        pre = S[i]
    if pre == "L":
        ans[idx] += (cur + 1) // 2
        ans[idx - 1] += cur // 2
    else:
        ans[idx] += cur
    print((*ans))


if __name__ == "__main__":
    main()

-S = eval(input()) -n = len(S) -ans = [0 for i in range(n)] -for i in range(n): -    if S[i : i + 2] == "RL": -        for j in range(i, -1, -1): -            if S[j] == "R": -                ans[i + (i - j) % 2] += 1 +def main(): +    S = eval(input()) +    N = len(S) +    idx = 0 +    cur = 1 +    pre = S[0] +    ans = [0] * N +    for i in range(1, N): +        # print(i, idx, cur, ans) +        if pre == S[i] == "R": +            idx += 1 +            cur += 1 +        elif pre == S[i] == "L": +            cur += 1 +        elif pre != S[i] == "R": +            if 0 <= idx - 1: +                ans[idx - 1] += cur // 2 +                ans[idx] += (cur + 1) // 2 -                break -        for j in range(i + 1, n): -            if S[j] == "L": -                ans[i + (j - i) % 2] += 1 -            else: -                break -print((*ans)) +                ans[idx] += cur +            idx = i +            cur = 1 +        elif pre != S[i] == "L": +            ans[idx] += (cur + 1) // 2 +            ans[idx + 1] += cur // 2 +            idx = i +            cur = 1 +        pre = S[i] +    if pre == "L": +        ans[idx] += (cur + 1) // 2 +        ans[idx - 1] += cur // 2 +    else: +        ans[idx] += cur +    print((*ans)) + + +if __name__ == "__main__": +    main()