using System;
using System.Collections.Generic;
using System.Linq;

namespace debug
{
    public static partial class Program
    {
        public class CharLong
        {
            public char c;
            public long l;
            public CharLong(char c, long l)
            {
                this.c = c;
                this.l = l;
            }
        }
        
        public static void Main()
        {
            var str = Console.ReadLine();
            var n = str.Length;
            
            var lr = str[0];
            var array = new List<CharLong>();
            array.Add(new CharLong(str[0], 1));
            for (int i = 1; i < n; i++)
            {
                if (str[i] == str[i - 1])
                {
                    array[array.Count - 1].l++;
                }
                else
                {
                    array.Add(new CharLong(str[i], 1));
                }
            }

            var output = new List<long>();
            for (int i = 0; i < array.Count; i++)
            {
                var r = array[i++];
                var l = array[i];

                // 左側
                for (int j = 0; j < r.l - 1; j++)
                {
                    output.Add(0);
                }

                // 奇数同士＆偶数同士
                if (r.l.IsEven() == l.l.IsEven())
                {
                    var num = (r.l + l.l) / 2;
                    output.Add(num);
                    output.Add(num);
                }
                else
                {
                    var num = (r.l + l.l) / 2.0;
                    var min = Math.Floor(num).ToLong();
                    var max = Math.Ceiling(num).ToLong();
                    if (r.l.IsEven())
                    {
                        output.Add(min);
                        output.Add(max);
                    }
                    else
                    {
                        output.Add(max);
                        output.Add(min);
                    }
                }
                
                // 右側
                for (int j = 0; j < l.l - 1; j++)
                {
                    output.Add(0);
                }
            }

            Console.WriteLine(output.JoinToStr(" "));
        }
    }

    public static partial class Program
    {
        //テンプレここから
        private static long GCD(long aaa, long bbb) => bbb == 0 ? aaa : GCD(bbb, aaa % bbb);
        private static long LCM(long aaa, long bbb) => aaa * bbb / GCD(aaa, bbb);
        private static long ToLong(this double ddd) => (long) ddd;
        private static long ToLong(this string str) => long.Parse(str);
        private static long[] ToLong(this IEnumerable<string> strs) => strs.Select(x => x.ToLong()).ToArray();
        private static long[] ToLongArray(this string str, char opr = ' ') => str.Split(opr).ToLong();
        private static long Diff(long aaa, long bbb) => Math.Abs(Math.Max(aaa, bbb) - Math.Min(aaa, bbb));
        private static long Sign(this long iii) => Math.Sign(iii);
        private static bool IsEven(this long iii) => iii % 2 == 0;
        private static readonly int[] _Dx = {0, -1, 0, 1};
        private static readonly int[] _Dy = {-1, 0, 1, 0};
        public const int MOD = 1000000007;
        public const string UPPER_ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
        public const string LOWER_ALPHABET = "abcdefghijklmnopqrstuvwxyz";
        private static long ToLong(this char ccc) => ccc.ToString().ToLong();
        private static string Join(this IEnumerable<string> array, string sep = "") => string.Join(sep, array);
        private static string Join(this IEnumerable<char> array, string sep = "") => string.Join(sep, array);

        private static string JoinToStr(this IEnumerable<long> array, string sep = "")
            => array.Select(xxx => xxx.ToString()).Join(sep);

        public static string JoinToStr(this IEnumerable<int> array, string sep = "")
            => array.Select(xxx => xxx.ToString()).Join(sep);

        //テンプレここまで
    }
}

Measured memory_bytes: 25820