Introduction to STL in C++

About C++ STL :

In C++, Standard Template Library (STL) is a set of classes that provide different functions and programming data structures. It helps to easily store and accessing the elements using different techniques.

sinh() function in c++ stl

Components of STL in C++ :

In general, There are four components of STL in C++ :

  • Algorithms
  • Function
  • Containers
  • Iterators


Algorithms :

Different Algorithms are provided by the STL  which are following :

  • Sorting
  • Searching

Functions :

Containers :

Types of Containers :

Following are the types of containers available in STL :

  • Sequence Containers : Vector, List, Deque, Arrays
  • Containers Adaptors : Queue, Priority Queue, Stack
  • Associative Containers : Set, Multiset, Map, Multimap
  • Unordered Associative Containers :  Unordered Set, Unordered Multiset, Unordered Map, Unordered Multimap

Iterators :

Advantages of STL in C++ :

Programming style may be drastically altered by STL, enabling for more strong, reliable, and reusable code. By using STL, programmer may simplify their life and increase its efficiency. Additionally, STL is expandable, enabling the programmers to include their own containers and algorithms.

Prime Course Trailer

Related Banners

Get PrepInsta Prime & get Access to all 200+ courses offered by PrepInsta in One Subscription

Get over 200+ course One Subscription

Courses like AI/ML, Cloud Computing, Ethical Hacking, C, C++, Java, Python, DSA (All Languages), Competitive Coding (All Languages), TCS, Infosys, Wipro, Amazon, DBMS, SQL and others

Checkout list of all the video courses in PrepInsta Prime Subscription

Checkout list of all the video courses in PrepInsta Prime Subscription