insertion sort and quick sort were implemented