How do you allocate and deallocate memory in C++?
Use the malloc() function to allocate memory in designated blocks and the new function to create a new function. To reallocate memory, the realloc() function is used. When finished, always include a free() function in order to free up the memory. If you used new(), use delete() to free up the memory.
Is This Answer Correct ? | 0 Yes | 0 No |
What is ctime c++?
Explain how we implement exception handling in c++?
What are class and object in C++?
reading material is provided 3 books for c++ if u need more do let me know thnx i hve lots of material do let me know if u want it
What are punctuators in c++?
What is an iterator class in c++?
What is a pure virtual function? Why is it represented as = 0...how is the internal implementation for the same
Which of the following operator cannot be overloaded?
What c++ is used for?
template<class T, class X> class Obj { T my_t; X my_x; public: Obj(T t, X x) : my_t(t), my_x(x) { } }; Referring to the sample code above, which one of the following is a valid conversion operator for the type T? a) T operator T () { return my_t; } b) T operator(T) const { return my_t; } c) operator(T) { return my_t; } d) T operator T (const Obj &obj) { return obj.my_t; } e) operator T () const { return my_t; }
What is the main use of c++?
Explain the difference between struct and class in terms of access modifier.