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

int main() {
	string str;
	while (cin >> str) cout << str.length() << ' ';
	return 0;
}