import re while+1:_=raw_input();print' '.join(re.findall(~-len(_)/int(_[0])*'\w',_))