s=eval(input())

n=len(s)

guki=[0,0,"r",0]

ans=[0]*n

for i in range(n):

    if guki[2]=="r":

        if s[i]=="R":

            guki[(i-guki[3])%2]+=1

        else:

            ans[i]+=guki[(i-guki[3])%2]

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

            guki[0]=0

            guki[1]=1

            guki[2]="l"

            guki[3]=i-1

    else:

        if s[i]=="L":

            guki[(i-guki[3])%2]+=1

        else:

            ans[guki[3]]+=guki[(i-guki[3])%2]

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

            guki[0]=1

            guki[1]=0

            guki[2]="r"

            guki[3]=i

ans[guki[3]]+=guki[(n-guki[3])%2]

ans[guki[3]+1]+=guki[(n-guki[3]+1)%2]





# print(ans)

print((" ".join(map(str,ans))))
import bisect, copy, heapq, math, sys

from collections import *

from functools import lru_cache

from itertools import accumulate, combinations, permutations, product

def input():

    return sys.stdin.readline()[:-1]

def ruiseki(lst):

    return [0]+list(accumulate(lst))

def celi(a,b):

    return -(-a//b)

sys.setrecursionlimit(5000000)

mod=pow(10,9)+7

al=[chr(ord('a') + i) for i in range(26)]

direction=[[1,0],[0,1],[-1,0],[0,-1]]



s=eval(input())

n=len(s)

anslst=[0]*n



cnt=0

for i in range(n):

    if s[i]=="R":

        cnt+=1

    else:

        anslst[i]+=cnt//2

        anslst[i-1]+=(cnt+1)//2

        cnt=0



for i in range(n)[::-1]:

    if s[i]=="L":

        cnt+=1

    else:

        anslst[i]+=cnt//2

        if i+1<n:

            anslst[i+1]+=(cnt+1)//2

        cnt=0



print((*anslst))
s = eval(input())
n = len(s)
guki = [0, 0, "r", 0]
ans = [0] * n
for i in range(n):
    if guki[2] == "r":
        if s[i] == "R":
            guki[(i - guki[3]) % 2] += 1
        else:
            ans[i] += guki[(i - guki[3]) % 2]
            ans[i - 1] += guki[(i - guki[3] + 1) % 2]
            guki[0] = 0
            guki[1] = 1
            guki[2] = "l"
            guki[3] = i - 1
    else:
        if s[i] == "L":
            guki[(i - guki[3]) % 2] += 1
        else:
            ans[guki[3]] += guki[(i - guki[3]) % 2]
            ans[guki[3] + 1] += guki[(i - guki[3] + 1) % 2]
            guki[0] = 1
            guki[1] = 0
            guki[2] = "r"
            guki[3] = i
ans[guki[3]] += guki[(n - guki[3]) % 2]
ans[guki[3] + 1] += guki[(n - guki[3] + 1) % 2]
# print(ans)
print((" ".join(map(str, ans))))

import bisect, copy, heapq, math, sys
from collections import *
from functools import lru_cache
from itertools import accumulate, combinations, permutations, product


def input():
    return sys.stdin.readline()[:-1]


def ruiseki(lst):
    return [0] + list(accumulate(lst))


def celi(a, b):
    return -(-a // b)


sys.setrecursionlimit(5000000)
mod = pow(10, 9) + 7
al = [chr(ord("a") + i) for i in range(26)]
direction = [[1, 0], [0, 1], [-1, 0], [0, -1]]
s = eval(input())
n = len(s)
anslst = [0] * n
cnt = 0
for i in range(n):
    if s[i] == "R":
        cnt += 1
    else:
        anslst[i] += cnt // 2
        anslst[i - 1] += (cnt + 1) // 2
        cnt = 0
for i in range(n)[::-1]:
    if s[i] == "L":
        cnt += 1
    else:
        anslst[i] += cnt // 2
        if i + 1 < n:
            anslst[i + 1] += (cnt + 1) // 2
        cnt = 0
print((*anslst))

+import bisect, copy, heapq, math, sys +from collections import * +from functools import lru_cache +from itertools import accumulate, combinations, permutations, product + + +def input(): +    return sys.stdin.readline()[:-1] + + +def ruiseki(lst): +    return [0] + list(accumulate(lst)) + + +def celi(a, b): +    return -(-a // b) + + +sys.setrecursionlimit(5000000) +mod = pow(10, 9) + 7 +al = [chr(ord("a") + i) for i in range(26)] +direction = [[1, 0], [0, 1], [-1, 0], [0, -1]] -guki = [0, 0, "r", 0] -ans = [0] * n +anslst = [0] * n +cnt = 0 -    if guki[2] == "r": -        if s[i] == "R": -            guki[(i - guki[3]) % 2] += 1 -        else: -            ans[i] += guki[(i - guki[3]) % 2] -            ans[i - 1] += guki[(i - guki[3] + 1) % 2] -            guki[0] = 0 -            guki[1] = 1 -            guki[2] = "l" -            guki[3] = i - 1 +    if s[i] == "R": +        cnt += 1 -        if s[i] == "L": -            guki[(i - guki[3]) % 2] += 1 -        else: -            ans[guki[3]] += guki[(i - guki[3]) % 2] -            ans[guki[3] + 1] += guki[(i - guki[3] + 1) % 2] -            guki[0] = 1 -            guki[1] = 0 -            guki[2] = "r" -            guki[3] = i -ans[guki[3]] += guki[(n - guki[3]) % 2] -ans[guki[3] + 1] += guki[(n - guki[3] + 1) % 2] -# print(ans) -print((" ".join(map(str, ans)))) +        anslst[i] += cnt // 2 +        anslst[i - 1] += (cnt + 1) // 2 +        cnt = 0 +for i in range(n)[::-1]: +    if s[i] == "L": +        cnt += 1 +    else: +        anslst[i] += cnt // 2 +        if i + 1 < n: +            anslst[i + 1] += (cnt + 1) // 2 +        cnt = 0 +print((*anslst))