Quicksort has a worst case time complexity of O(n^2) when the pivot is always the minimum or maximum element, dividing the array into arrays of size 1 and n-1 on each iteration. The best case of O(n log n) occurs when the pivot evenly divides the array into two halves. On average, quicksort runs in O(n log n) time. Practical implementations avoid the worst case by randomly selecting the pivot or choosing the median element as the pivot on each iteration.