14134 - Strawhats' Bento Set   

Description

The Strawhats are departing Wano! 

Sanji is preparing bentos with a set of ingredients I.

He plans to make each bento with the set of all subsets of I, including I itself.

Chopper needs to list all the bento sets that Sanji is going to make. 

Take example, the set of Ingredients 1

Ingredients 1 = {"Rice", "Salmon"}

Then, the bento sets he is going to make are {{"Rice"}, {"Salmon"}, {"Rice", "Salmon"}}

Here is another example set of ingredients 2

Ingredients 2 = {"Rice", "Seaweed", "Meat"}

Then the bento sets he is going to make are {{"Rice"}, {"Seaweed"}, {"Rice", "Seaweed"}, {"Meat"}, {"Rice", "Meat"}, {"Seaweed", "Meat"}, {"Rice", "Seaweed", "Meat"}}

But Chopper is too lazy to write all the ingredients... So he decided to label everything into a single number or alphabet!!

The set of Ingredients 1 becomes  {'1', '2'} 

and the bento sets are  {{'1'}, {'2'}, {'1','2'}}

 

The set of Ingredients 2 becomes  {'1', '2', 'a'} 

and the bento sets are {{'1'}, {'2'}, {'1', '2'}, {'a'}, {'1','a'}, {'2','a'}, {'1','2','a'}}

 

Now help Chopper list the bento sets by the given specific set of ingredients.

Input

The stringthat can be viewed as a set. (4 < the length of < 21)

Output

Output the bento sets followed by a newline character at the end of each set

Sample Input  Download

Sample Output  Download

Tags




Discuss