#include <iostream>
#include <cstring>
using namespace std;

int main() {
	char str[20];
	while (cin >> str) cout << strlen(str) << ' ';
	return 0;
}