Advertisement
MOISES_QUISPE_ROJAS

Estructura Datos 2021 - ILinkedList

Oct 27th, 2021
917
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.80 KB | None | 0 0
  1. //
  2. // Created by Julio Tentor <jtentor@fi.unju.edu.ar>
  3. //
  4.  
  5. // from https://docs.oracle.com/en/java/javase/15/docs/api/java.base/java/util/LinkedList.html
  6. package List;
  7.  
  8. public interface ILinkedList<ELEMENT> extends Iterable<ELEMENT> {
  9.     // Returns the number of elements in this list.
  10.     public int size();
  11.     // Inserts the specified element at the beginning of this list.
  12.     public void addFirst(ELEMENT item);
  13.     // Appends the specified element to the end of this list.
  14.     public void addLast(ELEMENT item);
  15.     // Removes and returns the first element from this list.
  16.     public ELEMENT removeFirst();
  17.     // Removes and returns the last element from this list.
  18.     public ELEMENT removeLast();
  19.     // Public void addInOrden(ELEMENT item);
  20.     public ELEMENT peekFirst();  
  21. }
  22.  
  23.    
  24.  
  25.  
  26.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement