#include <bits/stdc++.h>
using namespace std;
struct k {
long long w, l;
};
k a[10000001];
k b[10000001];
long long cnt1 = 1;
long long cnt2 = 1;
int main() {
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
char c;
while (1) {
cin >> c;
if (c == 'E') {
break;
}
if (c == 'W') {
a[cnt1].w++;
b[cnt2].w++;
}
if (c == 'L') {
a[cnt1].l++;
b[cnt2].l++;
}
if ((a[cnt1].l>=11||a[cnt1].w>=11)&&abs(a[cnt1].w-a[cnt1].l)>=2) {
cnt1++;
}
if ((b[cnt2].w >=21|| b[cnt2].l == 21)&&abs(b[cnt2].w-b[cnt2].l)>=2) {
cnt2++;
}
}
for (int i = 1; i <= cnt1; i++) {
cout << a[i].w << ":" << a[i].l;
cout << endl;
}
cout << endl;
for (int i = 1; i <= cnt2; i++) {
cout << b[i].w << ":" << b[i].l;
cout << endl;
}
return 0;
}