Effective STL Directory

zhaozj2021-02-11  268

Since there is no content, some translations may not be accurate, please forgive :)

container

Terpall 1: Carefully choose the container clause 2: Careful to the "container unrelated code" Fantasy Terms 3: Make the copy operation of the object in the container and correct clause 4: Instead of checking if the size is 0: 5: Try to use the range member function instead of their single element brother clause 6: Be wary of C and its angry analysis Terms 7: When using new pointers, remember to destroy the delete clauses 8: Don't Put Auto_PTR into the container Terfection 9: Carefully Select Delete Option Terms 10: Beware of Allocator's Agreements and Constraint Terms 11: Understanding Custom Allocator's Orthodox Terms of Use 12: Expectance for thread security for STL containers Some

Vector and String

Terms 13: Try to use Vector and String to replace dynamic applications Array Terms: Use reserve to avoid unnecessary memory reassign clauses 15: Current String's implementation of the Change Terms 16: How to pass the data of Vector and String to tradition API Terms 17: Fixing Excessive Capacity Terms with "Exchange Skill" 18: Avoid using Vector

Related container

Terms 19: Understanding the Equivalent and Equity Terms 20: Specify comparison type Terms for the associated container containing pointers 21: Always let comparison functions return to False Terms for equal values ​​22: Avoid modifying clauses 23 for the key value of Set and MultiSet : Consider using the sorted Vector instead of related container clause 24: When the efficiency is critical, try to use map :: INSERT instead Map :: Operator Terms 25: Let yourself be familiar with non-standard Hash container

Iterator

Item 26: Try using iterator instead of const_iterator, reverse_iterator Terms and const_reverse_iterator 27: Use distance and advance to const_iterators converted into iterators clause 28: Learn how to get the iterator terms by base reverse_iterator 29: Whenever you need a character with a character input please istreambuf_iterator

algorithm

Terms 30: Make sure the purpose range is very big enough 31: Understand your sort option Terms 32: If you really want to delete something, after Remove-Like algorithm, ERASE Terms 33: Be careful to use REMOVE in container containing pointers- Like's algorithm Terms 34: Note which algorithms need to be sorted by Mismatch or Lexicographical_Compare Simple Ignore Size String Comparison Terms 36: Use Not1 and Remove_copy_IF to express COPY_IF Terms 37: Use Accumulate or for_each to Statistics Sequence

Imitation function, imitation function, functions, etc.

Terms 38: Designing the Terms of Value Value by Imitation Function Class 39: Predicate Terms 40: Enhanced Imitation Function Class Adaptability Terms 41: Clear PTR_FUN, MEM_FUN and MEM_FUN_REF Difference Terms 42: Guaranteed Less is Operator < meaning

STL programming

Terms 43: Try to call instead of handwriting Circulatory Terms 44: Try to use member functions to replace the same name algorithm 45: Note COUNT, FIND, Binary_Search, Difference Terms of COWER_BOUND, Upper_Bound and Equal_Range 46: Consider the function object instead of function as an algorithm Parameter Terms 47: Avoiding Code Code Terms 48: Always #include Proper Head File Terms 49: Learn to Crack STL Related Compiler Error Information Terms 50: Let yourself be familiar with STL-related sites

Appendix A. Local and ignored uppercase strings Comparison

Appendix B. Talk to Microsoft STL Platform

转载请注明原文地址:https://www.9cbs.com/read-4783.html

New Post(0)