I have trouble creating a sort alogrithm to sort an input of data. The data inputs will be a strings made up of three letters.
Example of how the program should run

data input- cot, atb, abc, dcc, tak, bak
after the first sort- atb,abc,dcc,tak,bak,cot
after the 2nd sort-tak,bak,abc,dcc,cot,atb
after the 3rd sort-abc,atb,bak,cot,dcc,tak
It will work work like radixsort, but the alogrithm has to be in mergesort, quicksort, heapsort

public class Sort{
public void myAlogrthims(int n, String[] inp)

Any help appreciated