#827. Permutations
You get a short word whose letters are all different. Print all its permutations in alphabetical order, one per line.
### Input
One word (1-4 letters).
### Output
Answer.
Examples
Input
xd
Output
dx xd
Input
dxcb
Output
bcdx bcxd bdcx bdxc bxcd bxdc cbdx cbxd cdbx cdxb cxbd cxdb dbcx dbxc dcbx dcxb dxbc dxcb xbcd xbdc xcbd xcdb xdbc xdcb
💡 You can solve it with Python, JavaScript or blocks. Read the input line by line with input(). Don't print a question (like input("Number: ")). Print exactly what the output asks for, nothing more.