Is there a new/delete equivalent of realloc?
Answer / rohit sah
No. It would have a number of difficult problems. Some of these are:
- Should the old instances in the memory be deleted and re-instantiated?
- How about contained classes?
- How about instances owned by the classes to be reallocated? These often have a pointer to their owner.
| Is This Answer Correct ? | 0 Yes | 0 No |
How do you print a string on the printer?
Why do we use string in c++?
How many types of casting are there in C++? When is a dynamic cast,static_cast,reinterpret cast used?
Explain how to initialize a const data member.
What is the difference between an array and a list?
Tell me an example where stacks are useful?
what is multi-threading in C++?
Why is c++ is better than c?
What is c++ coding?
Does std endl flush?
Why should you learn c++?
show that among any group of five (not necessary consecutive ) integers, there are two with the same remainder when divided by 4.