简体   繁体   中英

C++ Snippets Library

You know those annoying things that C++ doesn't do very intuitively, like splitting strings on custom delimiters or creating dynamically expanding arrays/vectors... is there any snippet library (I keep seeing boost all over the place, please let me know if that is the solution), that I should be aware of? Or maybe a website that has a number of them so that I can refresh my knowledge of C++... anything to that end is acceptable.

Thanks SOCommunity!

The two particular examples you give are both covered by the standard library - stringstream and getline() to split strings, and vector for a dynamic array.

That should be the first place to look; Boost is a good resource when the standard library doesn't meet your needs.

对于动态扩展向量,应使用STL。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM