An introduction to algorithms for readers with no background in advanced mathematics or computer science, emphasizing examples and real-world problems.
Algorithms are what we do in order not to have to do something. Algorithms consist of instructions to carry out tasks—usually dull, repetitive ones. Starting from simple building blocks, computer algorithms enable machines to recognize and produce speech, translate texts, categorize and summarize documents, describe images, and predict the weather. A task that would take hours can be completed in virtually no time by using a few lines of code in a modern scripting program.
This book offers an introduction to algorithms through the real-world problems they solve. The algorithms are presented in pseudocode and can readily be implemented in a computer language.
The book presents algorithms simply and accessibly, without overwhelming readers or testing their intelligence. Readers should be comfortable with mathematical fundamentals and have a basic understanding of how computers work; all other necessary concepts are explained in the text. After presenting background in pseudocode conventions, basic terminology, and data structures, chapters cover compression, cryptography, graphs, searching and sorting, hashing, classification, strings, and chance. Each chapter describes real problems and then presents algorithms to solve them. Examples illustrate the wide range of applications, including shortest paths as a solution to paragraph line breaks, strongest paths in elections systems, hashes for song recognition, voting power Monte Carlo methods, and entropy for machine learning. It is meant for undergraduate computer science students. Students in other streams such as applied sciences can also benefit from it.
“A broad survey of algorithmic ideas that avoids the standard ‘greatest hits’ approach. It includes advanced topics like voting systems and text compression that are not covered in most introductory algorithm books. Beginners will be running before they can walk!”
Distinguished Teaching Professor, Department of Computer Science, Stony Brook University;
author of The Algorithm Design Manual