simple version of quick sort