Maps in C++ (std::map and std::unordered_map)

Maps in C++ (std::map and std::unordered_map)

246.384 Lượt nghe
Maps in C++ (std::map and std::unordered_map)
For all your web hosting needs (use coupon code CHERNO for a discount) ► https://hostinger.com/cherno Patreon ► https://patreon.com/thecherno Instagram ► https://instagram.com/thecherno Twitter ► https://twitter.com/thecherno Discord ► https://discord.gg/thecherno My C++ series ► https://www.youtube.com/playlist?list=PLlrATfBNZ98dudnM48yfGUldqGD0S4FFb Chapters: ---------------- 0:00 - What are maps? 3:40 - Why use maps + example usage 9:30 - Writing a hash function to use a custom type 16:50 - The [] operator 19:00 - The .at() function 20:40 - How to check if key exists in map 21:11 - How to iterate through maps 24:47 - How to remove entries from maps 25:03 - Writing a less-than operator for custom types 28:05 - Performance and which map to use This video is sponsored by Hostinger.