quick sort added and functional