O'Reilly logo

Python Algorithms: Mastering Basic Algorithms in the Python Language, Second Edition by Magnus Lie Hetland

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 2

image

The Basics

Tracey: I didn’t know you were out there.

Zoe: Sort of the point. Stealth—you may have heard of it.

Tracey: I don’t think they covered that in basic.

— From “The Message,” episode 14 of Firefly

Before moving on to the mathematical techniques, algorithmic design principles, and classical algorithms that make up the bulk of this book, we need to go through some basic principles and techniques. When you start reading the following chapters, you should be clear on the meaning of phrases such as “directed, weighted graph without negative cycles” and “a running time of Θ(n lg n).” You should also have an idea of how to implement ...

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