Virtusa Interview Question

Sorting program with less time complexity