s = eval(input())

N = len(s)

ls = [0] + [i for i in range(1,N) if (s[i-1]=='L' and s[i] == 'R')]

ls.append(N)

#print(ls)

ls2 = [(ls[i],ls[i+1]) for i in range(len(ls)-1)]

#print(ls2)

ls3 = [i for i in range(1,N) if (s[i-1]=='R' and s[i] == 'L')]

#print(ls3)

res = ['0']*N

for i,tp in enumerate(ls2):

    for j in range(tp[0],tp[1]):

        res[ls3[i]] = str((tp[1]-ls3[i]-1)//2+(ls3[i]-tp[0])//2+1)

        res[ls3[i]-1] = str((tp[1]-ls3[i])//2+(ls3[i]-tp[0]-1)//2+1)

print((' '.join(res)))

s = eval(input())

N = len(s)

ls = [0] + [i for i in range(1,N) if (s[i-1]=='L' and s[i] == 'R')]

ls.append(N)

ls2 = [(ls[i],ls[i+1]) for i in range(len(ls)-1)]

ls3 = [i for i in range(1,N) if (s[i-1]=='R' and s[i] == 'L')]

res = ['0']*N

for i,tp in enumerate(ls2):

    res[ls3[i]] = str((tp[1]-ls3[i]-1)//2+(ls3[i]-tp[0])//2+1)

    res[ls3[i]-1] = str((tp[1]-ls3[i])//2+(ls3[i]-tp[0]-1)//2+1)

print((' '.join(res)))

s = eval(input())
N = len(s)
ls = [0] + [i for i in range(1, N) if (s[i - 1] == "L" and s[i] == "R")]
ls.append(N)
# print(ls)
ls2 = [(ls[i], ls[i + 1]) for i in range(len(ls) - 1)]
# print(ls2)
ls3 = [i for i in range(1, N) if (s[i - 1] == "R" and s[i] == "L")]
# print(ls3)
res = ["0"] * N
for i, tp in enumerate(ls2):
    for j in range(tp[0], tp[1]):
        res[ls3[i]] = str((tp[1] - ls3[i] - 1) // 2 + (ls3[i] - tp[0]) // 2 + 1)
        res[ls3[i] - 1] = str((tp[1] - ls3[i]) // 2 + (ls3[i] - tp[0] - 1) // 2 + 1)
print((" ".join(res)))

s = eval(input())
N = len(s)
ls = [0] + [i for i in range(1, N) if (s[i - 1] == "L" and s[i] == "R")]
ls.append(N)
ls2 = [(ls[i], ls[i + 1]) for i in range(len(ls) - 1)]
ls3 = [i for i in range(1, N) if (s[i - 1] == "R" and s[i] == "L")]
res = ["0"] * N
for i, tp in enumerate(ls2):
    res[ls3[i]] = str((tp[1] - ls3[i] - 1) // 2 + (ls3[i] - tp[0]) // 2 + 1)
    res[ls3[i] - 1] = str((tp[1] - ls3[i]) // 2 + (ls3[i] - tp[0] - 1) // 2 + 1)
print((" ".join(res)))

-# print(ls) -# print(ls2) -# print(ls3) -    for j in range(tp[0], tp[1]): -        res[ls3[i]] = str((tp[1] - ls3[i] - 1) // 2 + (ls3[i] - tp[0]) // 2 + 1) -        res[ls3[i] - 1] = str((tp[1] - ls3[i]) // 2 + (ls3[i] - tp[0] - 1) // 2 + 1) +    res[ls3[i]] = str((tp[1] - ls3[i] - 1) // 2 + (ls3[i] - tp[0]) // 2 + 1) +    res[ls3[i] - 1] = str((tp[1] - ls3[i]) // 2 + (ls3[i] - tp[0] - 1) // 2 + 1)