pivot chooses randomly