Added Total Oreder Sorting design patern.