#include<bits/stdc++.h>
using namespace std;
char s[62530];char c;
long long hh,dui,a,b;
long long p;
int main()
{
while(true){
cin>>c;
p++;
s[p]=c;
if(c=='E')break;
}
for(int i=0;i<=p;i++){
if(s[i]=='W'){
hh++;a++;
}
if(s[i]=='L'){
dui++;b++;
}
if(hh-dui>=2||dui-hh>=2)
if((hh>=11)||(dui>=11)){
cout<<hh<<":"<<dui<<endl;
hh=0;dui=0;
}
}cout<<hh%11<<":"<<dui%11;
cout<<endl<<endl;
hh=0;dui=0;a=0;b=0;
for(int i=0;i<=p;i++){
if(s[i]=='W'){
hh++;a++;
}
if(s[i]=='L'){
dui++;b++;
}if(hh-dui>=2||dui-hh>=2){
if((hh>=21)||(dui>=21)){
cout<<hh<<":"<<dui<<endl;
hh=0;dui=0;
}
}
}cout<<hh%21<<":"<<dui%21;
return 0;
}