//KZNS
#include <cstdio>
using namespace std;
char ls[1000000];
int u = 0;
void init() {
char c = getchar();
while (c != 'E') {
if (c == 'W' || c == 'L')
ls[u++] = c;
c = getchar();
}
}
int r11() {
int a = 0, b = 0;
for (int i = 0; i < u; i++) {
if (ls[i] == 'W')
a++;
else
b++;
if ((a >= 11 && a - b >= 2) || (b >= 11 && b - a >= 2)) {
printf("%d:%d\n", a, b);
a = 0;
b = 0;
}
}
printf("%d:%d\n", a, b);
}
int r21() {
int a = 0, b = 0;
for (int i = 0; i < u; i++) {
if (ls[i] == 'W')
a++;
else
b++;
if ((a >= 21 && a - b >= 2) || (b >= 21 && b - a >= 2)) {
printf("%d:%d\n", a, b);
a = 0;
b = 0;
}
}
printf("%d:%d\n", a, b);
}
int main() {
freopen("table.in", "r", stdin);
freopen("table.out", "w", stdout);
init();
r11();
printf("\n");
r21();
return 0;
}
//UBWH