Skip to Content
A Common-Sense Guide to Data Structures and Algorithms
book

A Common-Sense Guide to Data Structures and Algorithms

by Jay Wengrow
August 2017
Intermediate to advanced
222 pages
5h 3m
English
Pragmatic Bookshelf
Content preview from A Common-Sense Guide to Data Structures and Algorithms

Chapter 6Optimizing for Optimistic Scenarios

When evaluating the efficiency of an algorithm, we’ve focused primarily on how many steps the algorithm would take in a worst-case scenario. The rationale behind this is simple: if you’re prepared for the worst, things will turn out okay.

However, we’ll discover in this chapter that the worst-case scenario isn’t the only situation worth considering. Being able to consider all scenarios is an important skill that can help you choose the appropriate algorithm for every situation.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

A Common-Sense Guide to Data Structures and Algorithms, Second Edition, 2nd Edition

A Common-Sense Guide to Data Structures and Algorithms, Second Edition, 2nd Edition

Jay Wengrow

Publisher Resources

ISBN: 9781680502794Errata Page