Added code for quick sort