add basic sort algorithm