How to construct muliton object
Answers were Sorted based on User's Feedback
Answer / som shekhar
Multiton pattern is similar to singleton pattern but it
keeps the named instances in a key value pair.
In singleton pattern, the class will have only one instances
but in the multiton pattern it manages a map of named instances.
| Is This Answer Correct ? | 1 Yes | 0 No |
Difference between pass by value and pass by reference?
Write a program which uses functions like strcmp(), strcpy()? etc
What is the difference between mutex and binary semaphore?
Explain working of printf?
Explain public, protected, private in c++?
Write a program which uses Command Line Arguments
What is #include iomanip?
What is a parameterized type?
what is a class? Explain with an example.
Explain overriding.
class Foo { public: Foo(int i) { } }; class Bar : virtual Foo { public: Bar() { } }; Bar b; Referring to the above code, when the object 'b' is defined, a compiler error will occur. What action fixes the compiler error? a) Adding a virtual destructor to the class Bar b) Adding a constructor to Bar which takes an int parameter c) Adding "Foo()" to the Bar constructor d) Adding a copy constructor to the class Foo e) Adding "Foo(0)" to the Bar::Bar initializer list
How do you know that your class needs a virtual destructor?