25 Nov 2019

  • November 25, 2019
  • Amitraj
Components of Standered Template Library (STL)

The STL contains several components but at its core are 3 key components:-
    They are-

1. Container
2. Algorithm
3. Iterators


-> The Relatonship between The 3 STL components is:-







-> A Container is an object that actually stores data. it is a way data is organized in memory.
     The STL containers are implemented by Template classes and therefore can be easily customized to hold different types of data.


-> An Algorithm is a procedure that is used to process the data contained in the containers. The STL includes many different kinds of Algorithms to provide support to tasks such as Initializing, searching, sorting and merging. Algorithms are implemented by Template functions.


-> An Iterator is an object (like a pointer) that points to an element in a container. we can use iterators to move through the contents of container.
      Iterators are handled just like pointers. we can increment or decrement them. Iterators connect Algorithms with containers and play a key role in the manipulation of data stored in the containers.




























Related Posts:

  • Different paradiagrams for problem solving Programming paradigm: Programming paradigm means that the fundamental of computer programming. Programming style or methods are changed from language to language. There are three programming paradigm – 1.) Imperative / Proc… Read More
  • Operators in C and C++ Operators in C and C++ 1.) Arithmetic Operator:-              The type of operators are use to perform general mathematical functions such as Add, Sub, Multiply or Divide. -> The… Read More
  • History of C++ History of C++ -> The C++ language is an object-oriented programming language & is a combination of both low-level & high-level language – a Middle-Level Language. -> C++ was developed by a Danish Computer Sc… Read More
  • C++ Error handling during file operations C++ Error handling during file operations -> There are various errors occour while dealing with files- 1. A file which we are attempting to open for reading does not exist. 2. The file name used for a new file may Alre… Read More
  • Difference between procedure Oriented Programming and Object oriented Programming language Difference between procedure Oriented Programming and Object oriented Programming language 1.)  procedure Oriented Programming Or Structured Oriented (POP):- -> Importance is given to logic.(Algorithm) -> … Read More

Translate

Popular Posts