Skip to Main Content
Programming Pearls, 2nd Edition
book

Programming Pearls, 2nd Edition

by Jon Bentley
September 1999
Intermediate to advanced content levelIntermediate to advanced
256 pages
7h 38m
English
Addison-Wesley Professional
Content preview from Programming Pearls, 2nd Edition

Hints for Selected Problems

Column 1

4. Read Column 12.

5. Consider a two-pass algorithm.

6, 8, 9. Try key indexing.

10. Consider hashing, and don’t limit yourself to a computerized system.

11. This problem is for the birds.

12. How do you write without using a pen?

Column 2

1. Think about sorting, binary search and signatures.

2. Strive for an algorithm that runs in linear time.

5. Exploit the identity cba = (arbrcr)r.

7. Vyssotsky used a system utility and two one-shot programs that he wrote just for this job to rearrange data on tapes.

8. Consider the k smallest elements in the set.

9. The cost of s sequential searches is proportional to sn; the total cost of s binary searches is the cost of the searches plus the time required to sort ...

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

The Practice of Programming

The Practice of Programming

Brian W. Kernighan, Rob Pike
The Programmer's Brain

The Programmer's Brain

Felienne Hermans
Programming Interviews Exposed, 4th Edition

Programming Interviews Exposed, 4th Edition

John Mongan, Noah Suojanen Kindler, Eric Giguere
Programming Rust, 2nd Edition

Programming Rust, 2nd Edition

Jim Blandy, Jason Orendorff, Leonora F. S. Tindall

Publisher Resources

ISBN: 9780134498058Purchase book