#include <iostream>
#include <sstream>
#include <string>
using namespace std;
int main() {
//SetConsoleCP(1251);
//SetConsoleOutputCP(1251);
//^^с кодировками в винде сами, если что
size_t count = 0;
string s; getline(cin, s);
cout << "--- Words:" << endl;
for(stringstream sstr(s);sstr>>s;count++) cout << s << endl;
cout << "\n--- Total:" << count << endl;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8c3N0cmVhbT4KI2luY2x1ZGUgPHN0cmluZz4KCnVzaW5nIG5hbWVzcGFjZSBzdGQ7CgppbnQgbWFpbigpIHsKICAgIC8vU2V0Q29uc29sZUNQKDEyNTEpOwogICAgLy9TZXRDb25zb2xlT3V0cHV0Q1AoMTI1MSk7CiAgICAvL15e0YEg0LrQvtC00LjRgNC+0LLQutCw0LzQuCDQsiDQstC40L3QtNC1INGB0LDQvNC4LCDQtdGB0LvQuCDRh9GC0L4KICAgIHNpemVfdCBjb3VudCA9IDA7CiAgICBzdHJpbmcgczsgZ2V0bGluZShjaW4sIHMpOwogICAgY291dCA8PCAiLS0tIFdvcmRzOiIgPDwgZW5kbDsKICAgIGZvcihzdHJpbmdzdHJlYW0gc3N0cihzKTtzc3RyPj5zO2NvdW50KyspIGNvdXQgPDwgcyA8PCBlbmRsOwogICAgY291dCA8PCAiXG4tLS0gVG90YWw6IiA8PCBjb3VudCA8PCBlbmRsOwp9