All Subsequences order

unable to print the subsequences in lexicographical order
code link : https://ide.codingblocks.com/s/88435

Hi @himanshukumarclassic37.hk,
code you have sent seems not of all subsequences problem.

Iā€™m so sorry for the inconvenience.
code link : https://ide.codingblocks.com/s/88577

Hi see your ans is not in lexico order,so store the ans in arraylist and sort that arraylist before printing.

I have done the changes in my code that u had told me before but instead of printing in lexico order i am still getting subsequences in unsorted order.
code link : https://ide.codingblocks.com/s/88610

Hey,have a look at this: