C++ STL

C++ STL Unordered Set – std::unordered_set

In this tutorial you will learn about stl unordered set container in c++ and various functions applicable on it. Unordered Set comes under unordered containers. As we discussed in introduction to stl article, unordered containers internally implemented with hash tables. Each item calculated by hash function, to map to hash table. The main advantage is …

C++ STL Unordered Set – std::unordered_set Read More »

C++ STL Multimap Container – std::multimap

In this tutorial you will learn about stl multimap i.e., std::multimap and all functions applicable on it with some example code. In previous articles we already learned about std::map container. It is an associative container which give priority to key values. But problem with map is it won’t allow duplicate values. But multimap allows duplicate …

C++ STL Multimap Container – std::multimap Read More »

C++ STL Priority Queue – std::priority_queue

In this tutorial you will learn about STL priority queue in C++ i.e std::priority_queue and all functions applicable on it. std:: priority_queue is a container adaptor. This is almost same as queue container adaptor. i.e this also works as first in first out (FIFO). Elements always inserted at front position and deletion also done from front …

C++ STL Priority Queue – std::priority_queue Read More »

C++ STL Stack Container Adaptor – std::stack

In this tutorial you will learn about STL stack container adaptor in C++ i.e. std::stack and all functions which it provides. std::stack is a container adaptor. We know that container adaptors are not containers. They provide specific interfaces. Elements manipulated in container adaptors by encapsulated functions of specific classes. Stack operates in Last in First …

C++ STL Stack Container Adaptor – std::stack Read More »