If we have two arrays of equal size and we need to find out the median of those arrays.
We have two arrays X and Y:
where :
X ={ x1 , x2}
Y = {y1 , y2}
After merging these two arrays X + Y structure will look like something:
Smart pointer is a class object that acts like a pointer but it has some additional features.
For ex: in below function:
A functor is a function object which implements a function call operator. This function call operator can be called in a way that looks like it’s a function.
A pretty basic example:
Multiple inheritance is a powerful and tricky tool to use in C++ programming language but sometimes it needs to be handled with care.
Virtual inheritance is used when we are dealing with multiple inheritance but want to prevent multiple instances of same class appearing in inheritance hierarchy.
Consider below example :
About