import numpy as np

from scipy.sparse import csr_matrix

s = np.array(list(eval(input())), dtype='U1')

n = len(s)

child = np.ones(n,dtype=np.int32)

rows = np.arange(n)

cols = np.where(s == 'R', rows+1, rows-1)

x = csr_matrix((np.ones(n,dtype=np.int32),(rows,cols)),(n,n))



def power(x,n):

    if n == 1:

        return x

    y = power(x,n//2)

    y = y*y

    return x*y if n&1 else y



x = power(x,10**100)

print((*(child*x)))

import sys

read = sys.stdin.buffer.read

readline = sys.stdin.buffer.readline

readlines = sys.stdin.buffer.readlines



# doublingしてみる



import numpy as np



S = np.array(list(read().rstrip().decode('utf-8')))



L = len(S)

x = np.arange(L,dtype=np.int32)

x[S=='R'] += 1

x[S=='L'] -= 1

dp = [x]



for _ in range(20):

    x = dp[-1]

    dp.append(x[x])



answer = np.bincount(dp[-1],minlength=L)



print((' '.join(answer.astype(str))))
import numpy as np
from scipy.sparse import csr_matrix

s = np.array(list(eval(input())), dtype="U1")
n = len(s)
child = np.ones(n, dtype=np.int32)
rows = np.arange(n)
cols = np.where(s == "R", rows + 1, rows - 1)
x = csr_matrix((np.ones(n, dtype=np.int32), (rows, cols)), (n, n))


def power(x, n):
    if n == 1:
        return x
    y = power(x, n // 2)
    y = y * y
    return x * y if n & 1 else y


x = power(x, 10**100)
print((*(child * x)))

import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
# doublingしてみる
import numpy as np

S = np.array(list(read().rstrip().decode("utf-8")))
L = len(S)
x = np.arange(L, dtype=np.int32)
x[S == "R"] += 1
x[S == "L"] -= 1
dp = [x]
for _ in range(20):
    x = dp[-1]
    dp.append(x[x])
answer = np.bincount(dp[-1], minlength=L)
print((" ".join(answer.astype(str))))

+import sys + +read = sys.stdin.buffer.read +readline = sys.stdin.buffer.readline +readlines = sys.stdin.buffer.readlines +# doublingしてみる -from scipy.sparse import csr_matrix -s = np.array(list(eval(input())), dtype="U1") -n = len(s) -child = np.ones(n, dtype=np.int32) -rows = np.arange(n) -cols = np.where(s == "R", rows + 1, rows - 1) -x = csr_matrix((np.ones(n, dtype=np.int32), (rows, cols)), (n, n)) - - -def power(x, n): -    if n == 1: -        return x -    y = power(x, n // 2) -    y = y * y -    return x * y if n & 1 else y - - -x = power(x, 10**100) -print((*(child * x))) +S = np.array(list(read().rstrip().decode("utf-8"))) +L = len(S) +x = np.arange(L, dtype=np.int32) +x[S == "R"] += 1 +x[S == "L"] -= 1 +dp = [x] +for _ in range(20): +    x = dp[-1] +    dp.append(x[x]) +answer = np.bincount(dp[-1], minlength=L) +print((" ".join(answer.astype(str))))