I am making an array of pointers to objects. I initialize the array by setting every pointer to NULL to indicate that the array element points to no object (and has always pointed to no object). Whenever an new object is declared, the value of one of the array elements is pointed at the new object.

My problem is that whenever an object is removed from the array I would like to set the pointer at that element to a value such that I know a object was there, but has been deleted. I obviously cannot reset that pointer to NULL because NULL is my "flag" that the pointer at that element is, and always has, pointed to no objects. I need a unique "flaq" that indicates the pointer at that array element once pointed to an object but that it no longer does. Any suggestions as to how I can do this?