>>678
#include <iostream>
using namespace std;
#define BUF_SIZE 8192
void main()
{
int count = 1;
char line[BUF_SIZE];
while(true){
if (!cin.getline(line, BUF_SIZE)) break;

char* cur = line;
while (*cur) {
char* next = cur + 1;
if (*cur != ' ' && *cur != '\t') {
if (*next == '\0' || *cur!=*next) {
cout << *cur << '-' << count << ' ';
count = 1;
}
else {
count++;
}
}
cur++;
}
cout << endl;
}
cout << endl << "Completed" << endl;
}