assign6_s_f88/ProductInventory.cpp
/*****************************************************************************
 ~ProductInventory: Destroy head productList
 returns: NO RETURN
 ****************************************************************************/
~ProductInventory: Destroy head productList
returns: NO RETURN
~ProductInventory : Destroy head productList returns : NO RETURN
ProductInventory::~ProductInventory()
{
    ProductNode *p = productList;  
    ProductNode *n;                
    while (p!=NULL)
    {
        n = p->next;  
        delete p;
        p = n;     
    }
}
ProductInventory :: ~ ProductInventory ( ) { ProductNode * p = productList ; ProductNode * n ; while ( p != NULL ) { n = p -> next ; delete p ; p = n ; } }
~ProductInventory: Destroy head productList
returns: NO RETURN
~ProductInventory : Destroy head productList returns : NO RETURN
//pointer to head
 //pointer to save location
 //save address of next node
 //make p point to the next node
