a=input() *b,=map(print,sorted(a[~x:]for x in range(len(a))))