Problem: Joseph really likes the culture of Japan. Last year he learned Japanese traditional clothes and visual arts and now he is trying to find out the secret of the Japanese game called Nonogram.

In the one-dimensional version of the game, there is a row of n empty cells, some of which are to be filled with a pen. There is a description of a solution called a profile — a sequence of positive integers denoting the lengths of consecutive sets of filled cells. For example, the profile of [4, 3, 1] means that there are sets of four, three, and one filled cell, in that order, with at least one empty cell between successive sets.

<image>

A suitable solution for n = 12 and p = [4, 3, 1]. 

<image>

A wrong solution: the first four filled cells should be consecutive. 

<image>

A wrong solution: there should be at least one empty cell before the last filled cell. 

Joseph found out that for some numbers n and profiles p there are lots of ways to fill the cells to satisfy the profile. Now he is in the process of solving a nonogram consisting of n cells and a profile p. He has already created a mask of p — he has filled all the cells that must be filled in every solution of the nonogram.

<image>

The mask for n = 12 and p = [4, 3, 1]: all the filled cells above are filled in every solution. 

After a break, he lost the source profile p. He only has n and the mask m. Help Joseph find any profile p' with the mask m or say that there is no such profile and Joseph has made a mistake.

Input

The only line contains a string m — the mask of the source profile p. The length of m is n (1 ≤ n ≤ 100 000). The string m consists of symbols # and _ — denoting filled and empty cells respectively.

Output

If there is no profile with the mask m, output the number -1. Otherwise, on the first line, output an integer k — the number of integers in the profile p'. On the second line, output k integers of the profile p'.

Examples

Input


__#_____


Output


2
3 2 


Input


_#


Output


-1


Input


___


Output


0

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
#define SZ(X) ((int)(X).size())
#define ALL(X) (X).begin(), (X).end()
#define REP(I, N) for (int I = 0; I < (N); ++I)
#define REPP(I, A, B) for (int I = (A); I < (B); ++I)
#define RI(X) scanf("%d", &(X))
#define RII(X, Y) scanf("%d%d", &(X), &(Y))
#define RIII(X, Y, Z) scanf("%d%d%d", &(X), &(Y), &(Z))
#define DRI(X) int X; scanf("%d", &X)
#define DRII(X, Y) int X, Y; scanf("%d%d", &X, &Y)
#define DRIII(X, Y, Z) int X, Y, Z; scanf("%d%d%d", &X, &Y, &Z)
#define RS(X) scanf("%s", (X))
#define CASET int ___T, case_n = 1; scanf("%d ", &___T); while (___T-- > 0)
#define MP make_pair
#define PB push_back
#define MS0(X) memset((X), 0, sizeof((X)))
#define MS1(X) memset((X), -1, sizeof((X)))
#define LEN(X) strlen(X)
#define F first
#define S second
#define RF(x) freopen(x,"r",stdin)
#define WF(x) freopen(x,"w",stdout)
typedef long long LL;
using namespace std;
typedef pair<LL,LL> PLL;
typedef pair<int,int> PII;
const LL MOD = (LL)1e9+7;
const int SIZE = 2e5+5;
const LL INF = 1LL<<60;
const double eps = 1e-4;
const double PI=3.1415926535897932;
 
int n;
string inp;
vector<int> s;
 
bool solve(int x){// how many blank cells to leave at the end!
    vector<int> v = s;
    REP(i,n-x){
        if(!v[i])continue;
        if(i&&s[i-1])continue;
        if(i<x)return false;
        for(int j=i-1;j>=max(i-x-1,0);j--){
            if(v[j])return false;
            if(j>=i-x)v[j]=1;
        }
    }
    /*REP(i,n-x){
        printf("%d",v[i]);
    }puts("");*/
    int c0=0;//number of 0s in a row
    vector<PII> gaps;//gotta fill the gaps man
    REP(i,n-x){
        if(v[i]==0){
            c0++;
        }
        else{
            if(c0){
                gaps.PB({i-c0-(c0==i),i-1});
            }
            c0 = 0;
        }
    }
    if(c0){
        gaps.PB({n-x-c0,n-x});
    }
    for(PII g:gaps){
        int lg = g.S-g.F+1;
        if(lg==2)return 0;//we died :(
        if(lg==1)continue;
        if(lg%2){
            for(int j=g.F+1; j<g.S;j+=2){
                v[j]=1;
            }
        }
        else{
            if(x==1)return 0;//died again
            v[g.F+1]=v[g.F+2] = 1;
            for(int j=g.F+4; j<g.S;j+=2){
                v[j]=1;
            }
        }
    }
    /*REP(i,n-x){
        printf("%d",v[i]);
    }puts("");*/
    vector<int> ans;
    int cl = 0;
    REP(i,n-x){
        if(!v[i]){
            if(cl)ans.PB(cl);
            cl = 0;
        }
        else cl++;
    }
    if(cl)ans.PB(cl);
    printf("%d\n",SZ(ans));
    REP(i,SZ(ans)){
        if(i)printf(" ");
        printf("%d",ans[i]);
    }puts("");
    exit(0);
    return 0;
}
 
int main(){
    cin >> inp;
    n = SZ(inp);
    REP(i,n){
        s.PB(inp[i]=='#');
    }
    if (s[0] && s.back()){
        bool full = 1;
        REP(i,n-1){
            if(!s[i]&&!s[i+1]){
                full = 0;
            }
        }
        vector<int> ans;
        int cl = 0;
        REP(i,n){
            if(!s[i]){
                if(cl)ans.PB(cl);
                cl = 0;
            }
            else cl++;
        }
        if(cl)ans.PB(cl);
        if(full){
            printf("%d\n",SZ(ans));
            REP(i,SZ(ans)){
                if(i)printf(" ");
                printf("%d",ans[i]);
            }
            return 0;
        }
        else{
            puts("-1");return 0;
        }
    }
    if(n>=1&&s[n-1]==0)solve(1);
    if(n>=2&&s[n-1]==0&&s[n-2]==0)solve(2);
    if(n>=3&&s[n-1]==0&&s[n-2]==0&&s[n-3]==0)solve(3);
    puts("-1");
}