int* v=new int[10]; // Creating a dynamic array delete[] v; // delete the dynamic array v=nullptr; //recommended