#include <iostream>
#include <string>
#include <sstream>

using namespace std;

int main() {
	string str;
	while(getline(cin,str)) {
		stringstream ss(str);
		string line;
		while(getline(ss,line,',')) {
			cout << line << endl;
		}
		cout << endl;
	}

	return 0;
}