1

Is it fine to call delete twice for a pointer? #include using namespace std; int main() { int *ptr = new int; delete ptr; delete ptr; return 0; }

Correct Answer: no

Make the most of this question

This page focuses on one Object Oriented Programming (OOP) question from Engineering. After checking the answer, return to the topic list to practice more or run a timed set.

Object Oriented Programming (OOP) MCQ: Is it fine to call delete twice for a pointer? #include using namespace std; int main() { int *ptr = new int; delete ptr; delete ptr; return 0; } | Extra Education