Explain the time complexity of a basic sorting algorithm and how you would optimize it for a large dataset at Protegrity Usa.