#include <iostream>
#include <string>
int main() {
std::string s("mamku;v;jopu;ipal");
char c = ';';
for (int i = 0; i < s.size(); ++i) {
if (s[i] == c)
std::cout << std::endl;
else
std::cout << s[i];
}
std::cout << std::endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8c3RyaW5nPgoKaW50IG1haW4oKSB7CglzdGQ6OnN0cmluZyBzKCJtYW1rdTt2O2pvcHU7aXBhbCIpOwoJY2hhciBjID0gJzsnOwoJZm9yIChpbnQgaSA9IDA7IGkgPCBzLnNpemUoKTsgKytpKSB7CgkJaWYgKHNbaV0gPT0gYykKCQkJc3RkOjpjb3V0IDw8IHN0ZDo6ZW5kbDsKCQllbHNlCgkJCXN0ZDo6Y291dCA8PCBzW2ldOwoJfQoJc3RkOjpjb3V0IDw8IHN0ZDo6ZW5kbDsKCXJldHVybiAwOwp9