Introduction to Search

Search is the enumeration of a state space: finding the optimal solution by exhausting all possibilities, or counting the number of valid solutions.

There are many ways to optimize search, such as reducing the state space, changing the search order, and pruning.

Search is the foundation of some advanced algorithms. In OI, pure search is often also a way to obtain partial points, but very few problems can be solved for full points using pure search.

Exercises

This content comes from OI Wiki: Introduction to Search. See the original for authors and revision history. AIOJ has adapted the formatting, in-site links, and resource paths.

Content is shared under CC BY-SA 4.0 and SATA license; additional terms are governed by the original notice. Thanks to the OI Wiki authors and contributors; per the SATA terms, please visit the OI Wiki repository and star it to show your support.