How to approach this problem?

A typical lexicographical sort would be apple bat batman but I have to bring batman in 2nd position. How can I solve this?

@yobasu2015 using a comparator here a simple solution


dont forget to hit like and mark it as resolved if cleared :smiley: