from itertools import* for p in product(*id(0)%5*[raw_input()]):print`p`[2::5]