Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Learning Phase: Search in web for generics/templates in C++. Analyze what is generics and what's the purpose of using generics. Now write a generic function
Learning Phase: Search in web for generics/templates in C++. Analyze what is generics and what's the purpose of using generics. Now write a generic function for adding two different types of variables. e.g. : variable Add(variable a, variable b) [Here variable could be of any data type] If you are done with the learning phase, then do the following. Create your own STL library as mySTL.h Your assignment is to create a mySTL. h header file in C++ that will contain these templated classes and methods. Finally demonstrate the use of your mySTL library in a demo.cpp file. You must submit two cpp files 1. mySTL.cpp and 2. demo.cpp
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started