What are templates in C++ programming ?

By | February 5, 2015

What are templates in C++ programming ?

Templates are used in C++ to achieve generic programming and providing generic data types. It can be understood by following class template :

Example of generic function :