public class DequeAsArray
    extends QueueAsArray
    implements Deque
{
    public void enqueueHead(Object object)
    {
        if(count == array.length)
            throw new ContainerFullException();
        
        if(head-- == 0)
            head = array.getLength() - 1;
        
        array.put(head, object);
        ++count;
    }
    
    public Object dequeueHead()
    {
        return dequeue();
    }
    
    public Object getTail()
    {
        if(count == 0)
            throw new ContainerEmptyException();
        
        return array.get(array.getLength());
    }
    
    public void enqueueTail(Object object)
    {
        enqueue(object);
    }
    
    public Object dequeueTail()
    {
        if(count == 0)
            throw new ContainerEmptyException();
        
        Object result = array.get(getTail());
        
        
    }
}
@@ -67,16 +67,84 @@
 Deque%0A%7B%0A
+    public DequeAsArray()%0A    %7B%0A        QueueAsArray(0);%0A    %7D%0A    %0A
     publ
@@ -214,14 +214,19 @@
 ray.
-l
+getL
 ength
+()
 )%0A  
@@ -631,33 +631,20 @@
 ray.get(
-array.getLength()
+tail
 );%0A    %7D
@@ -891,37 +891,169 @@
 get(
-getTail());%0A        %0A        
+tail);%0A        array.put(tail, null);%0A       %0A        if(count-- == 0)%0A            tail = array.getLength() - 1;%0A        %0A        --count;%0A        return result;
 %0A   

update Deque as Array implementation