AddLast() Method : Insert element at start ArrayDeque in Java

   

Declaration :

Explanation :

Purpose The java.util.ArrayDeque.addLast(E e) method inserts the specified element E at the end of the deque.
Parameters e ===> The element to be added at the end.
Return Value This method does not return any value.
Exception NullPointerException — if the specified element is null.

Java Program : Example

Below example will explain java.util.ArrayDeque.addLast(E) method.

Output of Program :