VOOZH about

URL: https://www.geeksforgeeks.org/java/deque-descendingiterator-method-in-java/

⇱ Deque descendingIterator() Method in Java - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Deque descendingIterator() Method in Java

Last Updated : 11 Jul, 2025

The descendingIterator() method of the Deque Interfacereturns an iterator over the elements in this deque in reverse order. The elements will be returned from the last to the first order. This can be used with any class implementing the Deque Interface like LinkedList, ArrayDeque, LinkedBlockingDeque, etc.

Syntax:

Iterator descendingIterator()

Example 1: Here, we are using the LinkedList as Deque.


Output
4
3
2
1

Example 2: Here, we are using the ArrayDeque as Deque.


Output
You
How Are
Geeks
Hello




Comment