O'Reilly logo

Using the C++ Standard Template Libraries by Ivor Horton

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 6

image

Sorting, Merging, Searching, and Partitioning

This chapter describes algorithms that are loosely related to sorting and merging ranges. Two groups of these specifically provide sorting and merging capabilities. Another group provides mechanisms for partitioning a range relative to a given element value. Two further groups provide ways of finding one or more elements in a range. In this chapter you’ll learn about:

  • How to sort a range defined by random access iterators into ascending or descending sequence.
  • How to prevent equal elements from being resequenced in a sort operation.
  • How to merge ordered ranges.
  • How you can search an unordered ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required