As a simple example, in a specific implementation of a dynamic array, we increase the size of the array each time. Because of this, array redistribution may be required, and in the worst case, O (n) may be required for insertion. However, a sequence of n inserts can always be performed at O ββ(n) time, since the remaining inserts are performed at constant time, so n attachments can be completed at O ββ(n) time. Thus, the amortized time for the operation is O (n) / n = O (1). - from Wiki
But in another book: each doubling takes O (n) time, but it is so rare that its amortized time is still O (1).
Hope someone can tell me that a rare situation brings out Vicki's explanation? Thanks
source share