Algorithms in C++ / Edition 1

Hardcover (Print)
Buy Used
Buy Used from BN.com
$48.74
(Save 25%)
Item is in good condition but packaging may have signs of shelf wear/aging or torn packaging.
Condition: Used – Good details
Used and New from Other Sellers
Used and New from Other Sellers
from $1.99
Usually ships in 1-2 business days
(Save 96%)
Other sellers (Hardcover)
  • All (34) from $1.99   
  • New (3) from $15.00   
  • Used (31) from $1.99   
Close
Sort by
Page 1 of 1
Showing All
Note: Marketplace items are not eligible for any BN.com coupons and promotions
$15.00
Seller since 2005

Feedback rating:

(223)

Condition:

New — never opened or used in original packaging.

Like New — packaging may have been opened. A "Like New" item is suitable to give as a gift.

Very Good — may have minor signs of wear on packaging but item works perfectly and has no damage.

Good — item is in good condition but packaging may have signs of shelf wear/aging or torn packaging. All specific defects should be noted in the Comments section associated with each item.

Acceptable — item is in working order but may show signs of wear such as scratches or torn packaging. All specific defects should be noted in the Comments section associated with each item.

Used — An item that has been opened and may show signs of wear. All specific defects should be noted in the Comments section associated with each item.

Refurbished — A used item that has been renewed or updated and verified to be in proper working condition. Not necessarily completed by the original manufacturer.

New
Reading, MA 1992 Hard cover New in fine dust jacket. sm stain on on outer pages, does not affect text-Book is clean & tight-text unmarked! Sewn binding. Cloth over boards. 672 ... p. Audience: General/trade. Read more Show Less

Ships from: Lindenhurst, NY

Usually ships in 1-2 business days

  • Canadian
  • Standard, 48 States
  • Standard (AK, HI)
  • Express, 48 States
  • Express (AK, HI)
$65.00
Seller since 2014

Feedback rating:

(151)

Condition: New
Brand new.

Ships from: acton, MA

Usually ships in 1-2 business days

  • Standard, 48 States
  • Standard (AK, HI)
$65.00
Seller since 2014

Feedback rating:

(151)

Condition: New
Brand new.

Ships from: acton, MA

Usually ships in 1-2 business days

  • Standard, 48 States
  • Standard (AK, HI)
Page 1 of 1
Showing All
Close
Sort by

Overview

The latest addition to Robert Sedgewick's popular series of books c arries his comprehensive collection of algorithms into anobject-oriented programming (OOP) environment with implementationin the C++ programming language. These algorithms cover a broadrange of fundamental and more advanced methods: sorting,searching, string-processing, geometric, graph, and mathematicalalgorithms. The algorithms are all expressed in terms of conciseimplementations in C++, so that readers can both appreciate theirbasic properties and test them on real applications.

The treatment of analysis of algorithsm is carefully developed. When appropriate, analytic results are discussed to illustratewhy certain algorithms are prefered, and in some cases, therelationship of the proactical algorithms being discussed topurely theoretical results is also described.

The ultimate aim of the book is to improve programming practice,whatever the environment, whatever the implementation language. Sedgweick describes the basic methods to be considered in everycase.

The algorithms included here cover a broad range of fundamental and more advanced methods: sorting, searching, string-processing, geometric, graph, and mathematical algorithms. Readers will see how key algorithms can be implemented, run, debugged, and used in real applications--plus why some algorithms are to be preferred over others.

Read More Show Less

Product Details

  • ISBN-13: 9780201510591
  • Publisher: Addison-Wesley
  • Publication date: 4/30/1992
  • Edition description: New Edition
  • Edition number: 1
  • Pages: 672
  • Product dimensions: 6.66 (w) x 9.54 (h) x 1.59 (d)

Meet the Author

Robert Sedgewick is the William O. Baker Professor of Computer Science at Princeton University. He is a Director of Adobe Systems and has served on the research staffs at Xerox PARC, IDA, and INRIA. He earned his Ph.D from Stanford University under Donald E. Knuth.
Read More Show Less

Read an Excerpt

This book is intended to survey the most important computeralgorithms in use today and to teach fundamental techniques tothe growing number of people in need of knowing them. It can beused as a textbook for a second, third, or fourth course incomputer science, after students have acquired some programmingskills and familiarity with computer systems, but before theyhave taken specialized courses in advanced areas of computerscience or computer applications.

Additionally, the book may be useful for self-study or as areference for those engaged in the development of computersystems or applications programs, since it contains a number ofimplementations of useful algorithms and detailed information ontheir performance characteristics. The broad perspective takenin the book makes it an appropriate introduction to the field.

The algorithms are expressed in the C++ programming language(versions of the book in Pascal and C are also available). Nospecific knowledge about the language is assumed—the treatmenthere is self-contained (though fast-paced). Readers who havesome familiarity with C++ will find the language a useful vehiclefor learning a variety of methods of practical interest. Readerswho have some familiarity with basic algorithms will find thetreatment here a useful vehicle for learning a variety offeatures of the C++ language, while at the same time learningsome new algorithms.

SCOPE

The book contains forty-five chapters grouped into eight majorparts: fundamentals, sorting, searching, string processing,geometric algorithms, graph algorithms, mathematical algorithmsand advanced topics. A major goal in developing this book hasbeen to bring together the fundamental methods from these diverseareas, in order to provide access to the best methods known forsolving problems by computer. Some of the chapters giveintroductory treatments of advanced material. It is hoped thatthe descriptions here can give readers some understanding of thebasic properties of fundamental algorithms ranging from priorityqueues and hashing to simplex and the fast Fourier transform.

One or two previous courses in computer science or equivalentprogramming experience are recommended for a reader to be able toappreciate the material in this book: one course in programmingin high-level languages such as C++, C or Pascal, and perhapsanother course which teaches fundamental concepts of programmingsystems. This book is thus intended for anyone conversant with amodern programming language and with the basic features of moderncomputer systems. References that might help fill in gaps inone's background are suggested in the text.

Most of the mathematical material supporting the analytic resultsis self-contained (or labeled as "beyond the scope" of thisbook), so little specific preparation in mathematics is requiredfor the bulk of the book, though a certain amount deal withalgorithms related to more advanced mathematical material—theseare intended to place the algorithms in context with othermethods throughout the book, not to teach the mathematicalmaterial. Thus the discussion of advanced mathematical conceptsis brief, general, and descriptive.

USE IN THE CURRICULUM

There is a great deal of flexibility in how the material here canbe taught. To a large extent, the individual chapters in thebook can be read independently of the others, though in somecases algorithms in one chapter make use of methods from aprevious chapter. The material can be adapted for use forvarious courses by selecting perhaps 25 or 30 of the 45 chapters,according to the taste of the instructor and the preparation ofthe students.

The book begins with an introductory section on data structuresand the design and analysis of algorithms. This sets the tonefor the rest of the book and provides a framework within whichmore advanced algorithms are treated. Some readers may skip orskim this section; others may learn the basics there.

An elementary course on "data structures and algorithms" mightomit some of the mathematical algorithms and some of the advancedtopics, then emphasize how various data structures are used inthe implementations. An intermediate course on "design andanalysis of algorithms" might omit some of the more practicallyoriented sections, then emphasize the identification and study ofthe ways in which algorithms achieve good asymptotic performance. A course on "software tools" might omit the mathematical andadvanced algorithmic material, then emphasize how to integratethe implementations given here into large programs or systems. Acourse on "algorithms" might take a survey approach and introduceconcepts from all these areas.

Some instructors may wish to add supplementary material to thecourses described above to reflect their particular orientation. For "data structures and algorithms," more mathematical analysiscould be added; and for "software tools", software engineeringtechniques could be covered in more depth. In this book,attention is paid to all these areas, but the emphasis is on thealgorithms themselves.

Earlier versions of this book have been used in recent years atscores of colleges and universities around the country as a textfor the second or third course in computer science and assupplemental reading for other courses. At Princeton, ourexperience has been that the breadth of coverage of material inthis book provides our majors with an introduction to computerscience that can be expanded upon in later courses on analysis ofalgorithms, systems programming and theoretical computer science,while at the same time providing all the students with a largeset of techniques that they can immediately put to good use.

There are 450 exercises ten following each chapter, thatgenerally divide into one of two types. Most are intended totest students' understanding of material in the next and askstudents to work through an example or apply concepts describedin the text. A few of them, however, involve implementing andputting together some of the algorithms, perhaps runningempirical studies to compare algorithms and to learn theirproperties.

ALGORITHMS OF PRACTICAL USE

The orientation of the book is toward algorithms likely to be ofpractical use. The emphasis is on teaching students the tools oftheir trade to the point that they can confidently implement, runand debug useful algorithms. Full implementations of the methodsdiscussed are included in the text, along with descriptions ofthe operations of these programs on a consistent set of examples. Indeed, as discussed in the epilog, hundreds of figures areincluded in the book that have been created by the algorithmsthemselves. Many algorithms are brought to light on an intuitivelevel through the visual dimension provided by these figures.

Characteristics of the algorithms and situations in which theymight be useful are discussed in detail. Though not emphasized,connections to the analysis of algorithms and theoreticalcomputer science are not ignored. When appropriate, empiricaland analytic results are discussed to illustrate why certainalgorithms are preferred. When interesting, the relationship ofthe practical algorithms being discussed to purely theoreticalresults is described. Specific information performancecharacteristics of algorithms is encapsulated throughout in"properties," important facts about the algorithms that deservefurther study.

Some algorithms are used in relatively small programs to solvespecific problems. Others play an integral part in relativelylarge systems. Many fundamental algorithms find application inboth domains. We indicate as appropriate how algorithms might bespecialized for use as problem-solving tools or generalized forintegration into much bigger programs. Such considerations areof particular interest for algorithms expressed in anobject-oriented language such as C++. In this book we providerelevant information that can be used to make intelligenttradeoffs between utility and performance in implementing widelyapplicable algorithms.

While there is little direct treatment of specific uses of thealgorithms in science and engineering applications, the potentialfor such use is mentioned when appropriate. Our experience hasbeen that when students learn good algorithms in a computerscience context early in their education, they are able to applythem to solve problems when warranted later on.

PROGRAMMING LANGUAGE

The programming language used throughout the book is C++ (Pascaland C versions of the book are also available). Any particularlanguage has advantages and disadvantages—our intention here isto provide access to the fundamental algorithms that have beendeveloped over the years to the growing number of people who aremoving to C++ as a primary language and using it forapplications. The programs can easily be translated to othermodern programming languages, since they are written in astylized form that are relatively language-independent. Indeed,many of the programs have been translated from Pascal, C, andother languages, though we try to use standard C++ idioms whenappropriate. On the other hand, C++ is particularly well-suitedto our task, because its basic support for data abstraction andmodular programming allows us to clearly express relationshipsamong algorithms and data structures.

Some of the programs can simplified by using more advancedlanguage feature, but this is true less often than one might think. Although language features are discussed when appropriate, thisbook is not intended to be reference work on C++ or onobject-oriented programming. While we use C++ classes heavily,we do not use templates, inheritance or virtual functions. Butthe algorithms are coded so as to ease the process of embeddingthem in large systems where such features can be used toadvantage in an object-oriented programming approach. Whenforced to make a choice, we concentrate on the algorithms, notlanguage feature or implementations details.

A goal of this book is to present the algorithms in as simple anddirect a form as possible. The programs are intended to be readnot by themselves, but as part of the surrounding text. Thisstyle was chosen as an alternative, for example, to having inlinecomments. The style is consistent whenever possible, so thatprograms that are similar look similar.

ACKNOWLEDGMENTS

Many people gave me helpful feedback on earlier versions of thisbook. In particular, students at Princeton and Brown sufferedthrough preliminary versions ofthe material in this book in the1980's. Special thanks are due to Trina Avery, Tom Freeman andJanet Incerpi for their help in producing the first edition. Iwould particularly like to thank Janet for converting the bookinto TeX format, adding the thousands of changes I made after the"last draft" of the first edition, guiding the files throughvarious systems to produce printed pages and even writing thescan-conversion routine for TeX used to produce draftmanuscripts, among many other things. Only after performing manyof these tasks myself for later versions do I truly appreciateJanet's contribution. I would also like to thank the manyreaders who provided me with detailed comments about the secondedition, including Guy Almes, Jay Gischer, Kennedy Lemke, UdiManber, Dana Richards, John Reif, M. Rosenfield, Stephen Seidman,and Michael Quinn.

Many of the designs in the figures are based on joint work withMarc Brown in the "electronic classroom" project at BrownUniversity in 1983. Marc's support and assistance in creatingthe designs (not tomention the system with which we worked) aregratefully acknowledged. I would like to acknowledge SarantosKapidakis' help in producing the endpapers.

This C++ version owes its existence to the persistence of KeithWollman who convinced me to proceed, and the patience of PeterGordon, who was confident that I would get around to doing so. Dave Hanson's willingness to answer questions about C and C++ wasinvaluable. I also would like to thank Darcy Cotten and SkipPlank for their help in producing the book.

Much of what I've written here I've learned from the teachingsand writings of Don Knuth, my advisor at Stanford. Though Donhad no direct influence on this work, his presence may be felt inthe book, for it was he who put the study of algorithms on ascientific footing that makes a work such as this possible.

I am very thankful for the support of Brown University and INRIAwhere I did most of the work on the book, and the Institute forDefense Analyses and the Xerox Palo Alto Research Center, where Idid some work on the book while visiting. Many parts of the bookare dependent on research that has been generously supported bythe National Science Foundation and the Office of Naval Research.Finally, I would like to thank Bill Bowen, Aaron Lemonick, andNeil Rudenstine at Princeton University for their support inbuilding an academic environment in which I was able to preparethis book, despite numerous other responsibilities.

Read More Show Less

Table of Contents

Ch. 1 Introduction 3
Ch. 2 Principles of Algorithm Analysis 27
Ch. 3 Elementary Data Structures 69
Ch. 4 Abstract Data Types 129
Ch. 5 Recursion and Trees 201
Ch. 6 Elementary Sorting Methods 265
Ch. 7 Quicksort 315
Ch. 8 Merging and Mergesort 347
Ch. 9 Priority Queues and Heapsort 373
Ch. 10 Radix Sorting 417
Ch. 11 Special-Purpose Sorts 451
Ch. 12 Symbol Tables and BSTs 489
Ch. 13 Balanced Trees 543
Ch. 14 Hashing 587
Ch. 15 Radix Search 623
Ch. 16 External Searching 669
Index 707
Read More Show Less

Preface

This book is intended to survey the most important computeralgorithms in use today and to teach fundamental techniques tothe growing number of people in need of knowing them. It can beused as a textbook for a second, third, or fourth course incomputer science, after students have acquired some programmingskills and familiarity with computer systems, but before theyhave taken specialized courses in advanced areas of computerscience or computer applications.

Additionally, the book may be useful for self-study or as areference for those engaged in the development of computersystems or applications programs, since it contains a number ofimplementations of useful algorithms and detailed information ontheir performance characteristics. The broad perspective takenin the book makes it an appropriate introduction to the field.

The algorithms are expressed in the C++ programming language(versions of the book in Pascal and C are also available). Nospecific knowledge about the language is assumed—the treatmenthere is self-contained (though fast-paced). Readers who havesome familiarity with C++ will find the language a useful vehiclefor learning a variety of methods of practical interest. Readerswho have some familiarity with basic algorithms will find thetreatment here a useful vehicle for learning a variety offeatures of the C++ language, while at the same time learningsome new algorithms.

SCOPE

The book contains forty-five chapters grouped into eight majorparts: fundamentals, sorting, searching, string processing,geometric algorithms, graph algorithms, mathematical algorithmsand advanced topics. Amajor goal in developing this book hasbeen to bring together the fundamental methods from these diverseareas, in order to provide access to the best methods known forsolving problems by computer. Some of the chapters giveintroductory treatments of advanced material. It is hoped thatthe descriptions here can give readers some understanding of thebasic properties of fundamental algorithms ranging from priorityqueues and hashing to simplex and the fast Fourier transform.

One or two previous courses in computer science or equivalentprogramming experience are recommended for a reader to be able toappreciate the material in this book: one course in programmingin high-level languages such as C++, C or Pascal, and perhapsanother course which teaches fundamental concepts of programmingsystems. This book is thus intended for anyone conversant with amodern programming language and with the basic features of moderncomputer systems. References that might help fill in gaps inone's background are suggested in the text.

Most of the mathematical material supporting the analytic resultsis self-contained (or labeled as "beyond the scope" of thisbook), so little specific preparation in mathematics is requiredfor the bulk of the book, though a certain amount deal withalgorithms related to more advanced mathematical material—theseare intended to place the algorithms in context with othermethods throughout the book, not to teach the mathematicalmaterial. Thus the discussion of advanced mathematical conceptsis brief, general, and descriptive.

USE IN THE CURRICULUM

There is a great deal of flexibility in how the material here canbe taught. To a large extent, the individual chapters in thebook can be read independently of the others, though in somecases algorithms in one chapter make use of methods from aprevious chapter. The material can be adapted for use forvarious courses by selecting perhaps 25 or 30 of the 45 chapters,according to the taste of the instructor and the preparation ofthe students.

The book begins with an introductory section on data structuresand the design and analysis of algorithms. This sets the tonefor the rest of the book and provides a framework within whichmore advanced algorithms are treated. Some readers may skip orskim this section; others may learn the basics there.

An elementary course on "data structures and algorithms" mightomit some of the mathematical algorithms and some of the advancedtopics, then emphasize how various data structures are used inthe implementations. An intermediate course on "design andanalysis of algorithms" might omit some of the more practicallyoriented sections, then emphasize the identification and study ofthe ways in which algorithms achieve good asymptotic performance. A course on "software tools" might omit the mathematical andadvanced algorithmic material, then emphasize how to integratethe implementations given here into large programs or systems. Acourse on "algorithms" might take a survey approach and introduceconcepts from all these areas.

Some instructors may wish to add supplementary material to thecourses described above to reflect their particular orientation. For "data structures and algorithms," more mathematical analysiscould be added; and for "software tools", software engineeringtechniques could be covered in more depth. In this book,attention is paid to all these areas, but the emphasis is on thealgorithms themselves.

Earlier versions of this book have been used in recent years atscores of colleges and universities around the country as a textfor the second or third course in computer science and assupplemental reading for other courses. At Princeton, ourexperience has been that the breadth of coverage of material inthis book provides our majors with an introduction to computerscience that can be expanded upon in later courses on analysis ofalgorithms, systems programming and theoretical computer science,while at the same time providing all the students with a largeset of techniques that they can immediately put to good use.

There are 450 exercises ten following each chapter, thatgenerally divide into one of two types. Most are intended totest students' understanding of material in the next and askstudents to work through an example or apply concepts describedin the text. A few of them, however, involve implementing andputting together some of the algorithms, perhaps runningempirical studies to compare algorithms and to learn theirproperties.

ALGORITHMS OF PRACTICAL USE

The orientation of the book is toward algorithms likely to be ofpractical use. The emphasis is on teaching students the tools oftheir trade to the point that they can confidently implement, runand debug useful algorithms. Full implementations of the methodsdiscussed are included in the text, along with descriptions ofthe operations of these programs on a consistent set of examples. Indeed, as discussed in the epilog, hundreds of figures areincluded in the book that have been created by the algorithmsthemselves. Many algorithms are brought to light on an intuitivelevel through the visual dimension provided by these figures.

Characteristics of the algorithms and situations in which theymight be useful are discussed in detail. Though not emphasized,connections to the analysis of algorithms and theoreticalcomputer science are not ignored. When appropriate, empiricaland analytic results are discussed to illustrate why certainalgorithms are preferred. When interesting, the relationship ofthe practical algorithms being discussed to purely theoreticalresults is described. Specific information performancecharacteristics of algorithms is encapsulated throughout in"properties," important facts about the algorithms that deservefurther study.

Some algorithms are used in relatively small programs to solvespecific problems. Others play an integral part in relativelylarge systems. Many fundamental algorithms find application inboth domains. We indicate as appropriate how algorithms might bespecialized for use as problem-solving tools or generalized forintegration into much bigger programs. Such considerations areof particular interest for algorithms expressed in anobject-oriented language such as C++. In this book we providerelevant information that can be used to make intelligenttradeoffs between utility and performance in implementing widelyapplicable algorithms.

While there is little direct treatment of specific uses of thealgorithms in science and engineering applications, the potentialfor such use is mentioned when appropriate. Our experience hasbeen that when students learn good algorithms in a computerscience context early in their education, they are able to applythem to solve problems when warranted later on.

PROGRAMMING LANGUAGE

The programming language used throughout the book is C++ (Pascaland C versions of the book are also available). Any particularlanguage has advantages and disadvantages—our intention here isto provide access to the fundamental algorithms that have beendeveloped over the years to the growing number of people who aremoving to C++ as a primary language and using it forapplications. The programs can easily be translated to othermodern programming languages, since they are written in astylized form that are relatively language-independent. Indeed,many of the programs have been translated from Pascal, C, andother languages, though we try to use standard C++ idioms whenappropriate. On the other hand, C++ is particularly well-suitedto our task, because its basic support for data abstraction andmodular programming allows us to clearly express relationshipsamong algorithms and data structures.

Some of the programs can simplified by using more advancedlanguage feature, but this is true less often than one might think. Although language features are discussed when appropriate, thisbook is not intended to be reference work on C++ or onobject-oriented programming. While we use C++ classes heavily,we do not use templates, inheritance or virtual functions. Butthe algorithms are coded so as to ease the process of embeddingthem in large systems where such features can be used toadvantage in an object-oriented programming approach. Whenforced to make a choice, we concentrate on the algorithms, notlanguage feature or implementations details.

A goal of this book is to present the algorithms in as simple anddirect a form as possible. The programs are intended to be readnot by themselves, but as part of the surrounding text. Thisstyle was chosen as an alternative, for example, to having inlinecomments. The style is consistent whenever possible, so thatprograms that are similar look similar.

ACKNOWLEDGMENTS

Many people gave me helpful feedback on earlier versions of thisbook. In particular, students at Princeton and Brown sufferedthrough preliminary versions ofthe material in this book in the1980's. Special thanks are due to Trina Avery, Tom Freeman andJanet Incerpi for their help in producing the first edition. Iwould particularly like to thank Janet for converting the bookinto TeX format, adding the thousands of changes I made after the"last draft" of the first edition, guiding the files throughvarious systems to produce printed pages and even writing thescan-conversion routine for TeX used to produce draftmanuscripts, among many other things. Only after performing manyof these tasks myself for later versions do I truly appreciateJanet's contribution. I would also like to thank the manyreaders who provided me with detailed comments about the secondedition, including Guy Almes, Jay Gischer, Kennedy Lemke, UdiManber, Dana Richards, John Reif, M. Rosenfield, Stephen Seidman,and Michael Quinn.

Many of the designs in the figures are based on joint work withMarc Brown in the "electronic classroom" project at BrownUniversity in 1983. Marc's support and assistance in creatingthe designs (not tomention the system with which we worked) aregratefully acknowledged. I would like to acknowledge SarantosKapidakis' help in producing the endpapers.

This C++ version owes its existence to the persistence of KeithWollman who convinced me to proceed, and the patience of PeterGordon, who was confident that I would get around to doing so. Dave Hanson's willingness to answer questions about C and C++ wasinvaluable. I also would like to thank Darcy Cotten and SkipPlank for their help in producing the book.

Much of what I've written here I've learned from the teachingsand writings of Don Knuth, my advisor at Stanford. Though Donhad no direct influence on this work, his presence may be felt inthe book, for it was he who put the study of algorithms on ascientific footing that makes a work such as this possible.

I am very thankful for the support of Brown University and INRIAwhere I did most of the work on the book, and the Institute forDefense Analyses and the Xerox Palo Alto Research Center, where Idid some work on the book while visiting. Many parts of the bookare dependent on research that has been generously supported bythe National Science Foundation and the Office of Naval Research.Finally, I would like to thank Bill Bowen, Aaron Lemonick, andNeil Rudenstine at Princeton University for their support inbuilding an academic environment in which I was able to preparethis book, despite numerous other responsibilities.



Read More Show Less

Customer Reviews

Be the first to write a review
( 0 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(0)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing 1 Customer Reviews
  • Anonymous

    Posted December 7, 2002

    Beyond cookbooks..

    This book teaches us beyond HOW TO COOK: (p126): "The median-of-three method helps Quicksort method helps Quicksort in three ways. First, it makes the worst case much more unlikely to occur in any actual sort. In order ofr the sort to take N^2 time, two out of the three elements examined must be among the largest or among the smallest elements in the file, and this must happen consistently through most of the partitions. Second, it eliminates the need for a sentinel before partitioning. Third, it actually reduces the total average running time of the algorithm by about 5%. The combination of a nonrecursive implementation of the median-of-three method with a cutoff for small subfiles can improve the running time of Quicksort over the naive recursive implementation by 25% to 30%. Further algorithmic improvements are possible (for example, the median of five or more elements could be used), but the amount of time gained will be marginal. More significant time savings can be realized (with less effort) by coding the inner loops (or the whole program) in machine language. Neither path is recommended except possibly for experts with serious sorting applications." Notice that this is the 1992 edition (downloadable or CD codes may very well be available by this time..you'll have to check for yourself) and there is no mention of downloadable codes mentioned. But for anyone who wants to really have the experience of someone who has DONE THE WORK behind them..the ANALYSIS alone is worth it's weight in code.

    Was this review helpful? Yes  No   Report this review
Sort by: Showing 1 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)