19.9 Big O Summary for This Chapter’s Searching and Sorting Algorithms

Figure 19.7 summarizes the searching and sorting algorithms covered in this chapter with the Big O for each. Figure 19.8 lists the Big O values we’ve covered in this chapter along with a number of values for n to highlight the differences in the growth rates.

Image

Fig. 19.7 | Searching and sorting algorithms with Big O values.

Image

Fig. 19.8 | Number of comparisons for common Big O notations.

Get Java™ How To Program (Early Objects), Tenth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.