How to stop conversions among objects?
Answers were Sorted based on User's Feedback
Answer / kavitha
If any situation like that the constructor should build the
objects and should not get used for carrying out
conversions, In that situation we are required to use the
explicit keyword with the constructor.
Is This Answer Correct ? | 1 Yes | 0 No |
Answer / v.senthil kumaran
Declare operator function (dummy) for assignment operator
in the private section of the class.
Is This Answer Correct ? | 0 Yes | 2 No |
What is a storage class in C++
What are the restrictions apply to constructors and destructors?
How much maximum can you allocate in a single call to malloc()?
Tell me what are static member functions?
What do you know about friend class and friend function?
What are the conditions that have to be met for a condition to be an invariant of the class?
Write a C++ program that asks the user to choose a number between 1 and 1000. Then, your program should be able to guess the number by asking the user no more than 10 yes/no questions. Use a while loop in your program
Explain the need for "Virtual Destructor"?
What are stacks? Give an example where they are useful.
How is memory managed in C++?
What is realloc() and free()? What is difference between them?
Can you write a function similar to printf()?