#include<bits/stdc++.h>
using namespace std;
#define ll long long
char c;
string s;
int main(){
cin.tie(0);
cout.tie(0);
while (cin >> c){
if (c == 'E') break;
s += c;
}
if (s.size() == 0){
cout << "0:0\n\n0:0";
return 0;
}
int me = 0, other = 0;
for (int i=0;i<s.size();i++){
if ((me - other >= 2 || other - me >= 2) && (me >= 11 || other >= 11)){
cout << me << ":" << other << endl;
me = 0, other = 0;
}
if (s[i] == 'W') me++;
else if (s[i] == 'L') other ++;
}
if (me !=0 || other != 0) cout << me << ":" << other << endl;
me = 0, other = 0;
cout << endl;
for (int i=0;i<s.size();i++){
if ((me - other >= 2 || other - me >= 2) &&(me >= 21 || other >= 21)){
cout << me << ":" << other << endl;
me = 0, other = 0;
}
if (s[i] == 'W') me++;
else if (s[i] == 'L') other ++;
}
if (me !=0 || other != 0) cout << me << ":" << other << endl;
me = 0, other = 0;
return 0;
}