Author: Stan Eisenstat
Subject: Re: [Cs223] can pushD() cause an overflow?
Date: Tuesday, 24 Mar 2020, 14:49:06
> Message Posted By: Unknown > > the spec indicates that pushD() should push values onto the head of the > deque. Since we are implementing the deque using two stacks, should we > worry about the case where a pushD() onto the H stack would cause an > overflow? The H stack is to be implemented with a headless linked list, the only possibility for overflow is that malloc() returns NULL. See the specification for what to do in that case. --Stan-PREV INDEX NEXT