• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/39

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

39 Cards in this Set

  • Front
  • Back

Queue:




Insert Element


Throws Exception if Operation fails

add(e)



Equivalent Deque Method: addLast()

Queue:




Insert Element


Returns special value if Operation fails

offer(e)



Equivalent Deque Method: offerLast()

Queue:




Remove Element


Throws Exception if Operation fails

remove()



Equivalent Deque Method: removeFirst()

Queue:




Examine Element (without removing it)


Throws Exception if Operation fails

element()



Equivalent Deque Method: getFirst()

Queue:




Examine Element (without removing it)


Returns special value if Operation fails

peek()



Equivalent Deque Method: peekFirst()

Queue:




Remove Element


Throws Exception if Operation fails

poll()



Equivalent Deque Method: pollFirst()

Deque:




Insert last Element (at tail)


Throws Exception if Operation fails

addLast(e)

Deque:




Insert last Element (at tail)


Returns special value if Operation fails

offerLast(e)

Deque:




Remove last Element (from tail)


Returns special value if Operation fails

pollLast()

Deque:




Remove last Element (from tail)


Throws Exception if Operation fails

removeLast()

Deque:




Examine last Element (at tail)


Throws Exception if Operation fails



getLast()

Deque:



Examine last Element (at tail)


Returns special value if Operation fails

peekLast()

Deque:




Insert first Element (at head)


Throws Exception if Operation fails

addFirst()

Deque:




Insert first Element (at head)


Returns special value if Operation fails

offerFirst()

Deque:




Remove first Element (at head)


Returns special value if Operation fails

pollFirst()

Deque:




Remove first Element (at head)


Throws Exception if Operation fails

removeFirst()

Deque:




Examine first Element (at head)


Throws Exception if Operation fails

getFirst()

Deque:




Examine first Element (at head)


Returns special value if Operation fails

peekFirst()

Stack:




Insert Element (on top of Stack)

push(e)


Equivalent Deque Method: addFirst()

Stack:




Remove Element (from top of Stack)


(Throws EmptyStackException - if this stack is empty.)

pop()



Equivalent Deque Method: removeFirst()

Stack:




Examine Element (on top of Stack)


(Throws EmptyStackException - if this stack is empty.)

peek()



Equivalent Deque Method: peekFirst()

What is the Equivalent Deque Method for the Queue Method add(e)?

addLast(e)

What is the Equivalent Deque Method for the Queue Method offer(e)?

offerLast(e)

What is the Equivalent Deque Method for the Queue Method remove()?

removeFirst()

What is the Equivalent Deque Method for the Queue Method poll()?

pollFirst()

What is the Equivalent Deque Method for the Queue Method element()?

getFirst()

What is the Equivalent Deque Method for the Queue Method peek()?

peekFirst()

What is the Equivalent Queue Method for the Deque Method addLast(e)?

add(e)

What is the Equivalent Queue Method for the Deque Method offerLast(e)?

offer(e)

What is the Equivalent Queue Method for the Deque Method removeFirst()?

remove()

What is the Equivalent Queue Method for the Deque Method pollFirst()?

poll()

What is the Equivalent Queue Method for the Deque Method getFirst()?

element()

What is the Equivalent Queue Method for the Deque Method peekFirst()?

peek()

What is the Equivalent Deque Method for the Stack Method push(e)?

addFirst(e)

What is the Equivalent Deque Method for the Stack Method pop()?

removeFirst()

What is the Equivalent Deque Method for the Stack Method peek()?

peekFirst()

What is the Equivalent Stack Method for the Deque Method addFirst(e)?

push(e)

What is the Equivalent Stack Method for the Deque Method removeFirst()?

pop()

What is the Equivalent Stack Method for the Deque Method peekFirst()?

peek()