Effective STL: 50 Specific Ways to Improve Your Use of Standard Template Library

4.2 avg rating
( 524 ratings by Goodreads )
 
9788177589085: Effective STL: 50 Specific Ways to Improve Your Use of Standard Template Library
View all copies of this ISBN edition:
 
 

BOOKS

"synopsis" may belong to another edition of this title.

Review:

Written for the intermediate or advanced C++ programmer, renowned C++ expert Scott Meyers provides essential techniques for getting more out of the Standard Template Library in Effective STL, a tutorial for doing more with this powerful library.

STL is a hugely powerful feature of today's C++, but one with a well-earned reputation for complexity. The book is organized into 50 tips that explore different areas of the STL. Besides providing a list of dos and don'ts, Meyers presents a lot of background on what works and what doesn't with STL. Each tip is demonstrated with in-depth coding samples, many of which make use of two-color printing to highlight the most important lines of code. (Advanced developers will enjoy Meyers's in-depth explanations, while those who are in a hurry can skip ahead to the recommended tip itself.)

A good part of this book involves using containers, like vectors and maps, which are built into STL. (Besides the standard built-in containers, the author also highlights recent additions to STL like B-trees, which are available as extensions from other vendors.) You'll learn the best ways to allocate, add, change, and delete items inside containers, including associative containers like maps. You'll also learn to avoid common pitfalls, which can result in writing code that is slow or just plain wrong.

Other areas covered in Effective STL cover getting the most out of the 100-plus STL algorithms that are bundled with this library. Meyers shows you how to choose the correct algorithm for sorting and other functions. (Even advanced developers will learn something here.) Sections on using function objects (called functors) round out the text. Meyers shows you when these classes make sense and the best ways to implement them. Besides specific tips, you'll get plenty of general programming advice. A useful appendix shows the limitations of STL as implemented in Microsoft Visual C++ 6.0 and how to overcome them.

Overall, Effective STL is a really invaluable source of programming expertise on an essential aspect of today's C++ for anyone who is using--or planning to use--STL in real production code. It is quite simply a must-have. --Richard Dragan

Topics covered:

  • Introduction to advanced Standard Template Library (STL) programming techniques
  • 50 tips and best practices for STL illustrated with sample tutorial code
  • Choosing containers
  • Efficient copying of elements inside containers
  • Removing, erasing, and cleaning up items from containers
  • Using custom allocators with STL containers
  • Thread safety with STL
  • Tips for programming with the STL vector and string classes (including reserving memory and calling legacy C/C++ code)
  • Tips for associative containers (including comparing items, sorted vectors, and non-standard enhancements to STL)
  • Tips for selecting and using STL iterator classes
  • STL algorithms (including sorting, removing, and comparing items)
  • Using functors with STL
  • General tips for STL programming (including advice for choosing algorithms and understanding compiler diagnostic messages)
  • String locales
  • Overcoming STL imitations in Microsoft Visual C++ 6.0

From the Back Cover:

"This is "Effective C++" volume three - it's really that good."
- Herb Sutter, independent consultant and secretary of the ISO/ANSI C++ standards committee "There are very few books which all C++ programmers "must" have. Add "Effective STL" to that list."
- Thomas Becker, Senior Software Engineer, Zephyr Associates, Inc., and columnist, "C/C++ Users Journal" C++'s Standard Template Library is revolutionary, but learning to use it well has always been a challenge. Until now. In this book, best-selling author Scott Meyers ("Effective C++," and "More Effective C++") reveals the critical rules of thumb employed by the experts - the things they almost always do or almost always avoid doing - to get the most out of the library. Other books describe "what's in" the STL. "Effective STL" shows you "how to use it." Each of the book's 50 guidelines is backed by Meyers' legendary analysis and incisive examples, so you'll learn not only what to do, but also "when" to do it - and "why." Highlights of "Effective STL" include:

  • Advice on choosing among standard STL containers (like vector and list), nonstandard STL containers (like hash_set and hash_map), and non-STL containers (like bitset).
  • Techniques to maximize the efficiency of the STL and the programs that use it.
  • Insights into the behavior of iterators, function objects, and allocators, including things you should "not" do.
  • Guidance for the proper use of algorithms and member functions whose names are the same (e.g., find), but whose actions differ in subtle (but important) ways.
  • Discussions of potential portability problems, including straightforward ways to avoid them.
Like Meyers' previous books, "Effective STL" is filled with proven wisdom that comes only from experience. Its clear, concise, penetrating style makes it an essential resource for every STL programmer.

"About this title" may belong to another edition of this title.

Other Popular Editions of the Same Title

9780201749625: Effective STL: 50 Specific Ways to Improve Your Use of the Standard Template Library

Featured Edition

ISBN 10:  0201749629 ISBN 13:  9780201749625
Publisher: Addison-Wesley Professional, 2001
Softcover

Top Search Results from the AbeBooks Marketplace

1.

MEYERS
Published by PEARSON
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Paperback Quantity Available: 1
Seller:
Free Shipping Books
(Toledo, OH, U.S.A.)

Book Description PEARSON. Paperback. Condition: VERY GOOD. Light rubbing wear to cover, spine and page edges. Very minimal writing or notations in margins not affecting the text. Possible clean ex-library copy, with their stickers and or stamp(s). Seller Inventory # 3018286748

More information about this seller | Contact this seller

Buy Used
US$ 31.74
Convert currency

Add to Basket

Shipping: FREE
Within U.S.A.
Destination, rates & speeds

2.

MEYERS
Published by PEARSON
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Paperback Quantity Available: 1
Seller:
ThriftBooks
(AURORA, IL, U.S.A.)

Book Description PEARSON. Paperback. Condition: Good. A copy that has been read, but remains in clean condition. All pages are intact, and the cover is intact. The spine may show signs of wear. Pages can include limited notes and highlighting, and the copy can include previous owner inscriptions. At ThriftBooks, our motto is: Read More, Spend Less. Seller Inventory # G8177589083I3N00

More information about this seller | Contact this seller

Buy Used
US$ 33.42
Convert currency

Add to Basket

Shipping: FREE
Within U.S.A.
Destination, rates & speeds

3.

MEYERS
Published by PEARSON (2001)
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Softcover Quantity Available: 1
Seller:
GlassFrogBooks
(Hawthorne, CA, U.S.A.)

Book Description PEARSON, 2001. Condition: Good. A+ Customer service! Satisfaction Guaranteed! Book is in Used-Good condition. Pages and cover are clean and intact. Used items may not include supplementary materials such as CDs or access codes. May show signs of minor shelf wear and contain limited notes and highlighting. Seller Inventory # 8177589083-2-4

More information about this seller | Contact this seller

Buy Used
US$ 38.01
Convert currency

Add to Basket

Shipping: FREE
Within U.S.A.
Destination, rates & speeds

4.

Scott Meyers
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Paperback Quantity Available: 1
Seller:
WorldofBooks
(Goring-By-Sea, WS, United Kingdom)

Book Description Paperback. Condition: Very Good. The book has been read, but is in excellent condition. Pages are intact and not marred by notes or highlighting. The spine remains undamaged. Seller Inventory # GOR009424963

More information about this seller | Contact this seller

Buy Used
US$ 34.37
Convert currency

Add to Basket

Shipping: US$ 3.80
From United Kingdom to U.S.A.
Destination, rates & speeds
International Edition
International Edition

5.

Meyers, Scott
Published by Pearson Education India (2006)
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Paperback Quantity Available: 1
International Edition
Seller:
HPB-Ohio
(Dallas, TX, U.S.A.)

Book Description Pearson Education India, 2006. Paperback. Condition: Good. International Edition Item may show signs of shelf wear. Pages may include limited notes and highlighting. May include supplemental or companion materials if applicable. Access codes may or may not work. Connecting readers since 1972. Customer service is our top priority. Seller Inventory # mon0001251660

More information about this seller | Contact this seller

Buy Used
US$ 38.75
Convert currency

Add to Basket

Shipping: US$ 3.99
Within U.S.A.
Destination, rates & speeds

6.

MEYERS
Published by PEARSON (2001)
ISBN 10: 8177589083 ISBN 13: 9788177589085
Used Softcover Quantity Available: 1
Seller:
Irish Booksellers
(Portland, ME, U.S.A.)

Book Description PEARSON, 2001. Condition: UsedAcceptable. book. Seller Inventory # M8177589083_4

More information about this seller | Contact this seller

Buy Used
US$ 39.85
Convert currency

Add to Basket

Shipping: US$ 3.27
Within U.S.A.
Destination, rates & speeds