//Copies the Queue elements to the end of the ArrayList.