Online Java Compiler By
JavaTpoint.com
import java.util.ArrayDeque; import java.util.Deque; public class JavaDequepollFirstExample3 { public static void main(String[] args) { Deque
deque = new ArrayDeque<>(); deque.offer(88l); deque.offer(78l); deque.offer(67l); Long val = deque.peek(); System.out.println("The first long value is given as : "+val); System.out.println("The resultant deque is : "+deque); }
Output