19.10 Wrap-Up

This chapter introduced searching and sorting. We discussed two searching algorithms—linear search and binary search—and three sorting algorithms—selection sort, insertion sort and merge sort. We introduced Big O notation, which helps you analyze the efficiency of an algorithm. The next two chapters continue our discussion of dynamic data structures that can grow or shrink at execution time. Chapter 20 demonstrates how to use Java’s generics capabilities to implement generic methods and classes. Chapter 21 discusses the details of implementing generic data structures. Each of the algorithms in this chapter is “single threaded”—in Chapter 23, Concurrency, we’ll discuss multithreading and how it can help you program for better performance ...

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.