What do you mean by a template?
Answer / Monitosh Sharma
A template is a construct in C++ that allows the creation of generic functions or classes, which can be instantiated multiple times with different types. Templates enable code reuse and improve efficiency by avoiding the need for separate function or class definitions for each type.
| Is This Answer Correct ? | 0 Yes | 0 No |
Explain how an exception handler is defined and invoked in a Program.
How should a contructor handle a failure?
What is the basic concept of c++?
What is the benefit of c++?
What is the difference between method and message?
Describe about storage allocation and scope of global, extern, static, local and register variables?
You're given an array containing both positive and negative integers and required to find the sub-array with the largest sum (O(N) a la KBL). Write a routine in C for the above.
What is the most useful programming language?
Differentiate between an inspector and a mutator ?
Can java be faster than c++?
How the keyword struct is different from the keyword class in c++?
What is the error in the code below and how should it be corrected?