Stacks and Queues

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/17

flashcard set

Earn XP

Description and Tags

Flashcards to help review key concepts related to stacks, queues, and their implementations.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

18 Terms

1
New cards

Stack

A data structure that follows the Last-In, First-Out (LIFO) principle, meaning the last item added is the first to be removed.

2
New cards

LIFO

Last-In, First-Out; a storage policy where the last element added is the first one to be removed.

3
New cards

Queue

A data structure that follows the First-In, First-Out (FIFO) principle, meaning the first item added is the first to be removed.

4
New cards

FIFO

First-In, First-Out; a storage policy where the first element added is the first one to be removed.

5
New cards

Push

An operation to add an element to the top of the stack.

6
New cards

Pop

An operation to remove the top element from the stack.

7
New cards

Peek

An operation to view the top element of the stack without removing it.

8
New cards

isEmpty

A method that checks if the stack or queue is empty.

9
New cards

Deque

A double-ended queue allowing insertions and removals from both ends.

10
New cards

Palindrome

A string that reads the same forwards and backwards, ignoring case.

11
New cards

Implementation of Stack

Can be done using an ArrayList, LinkedList, or an Array.

12
New cards

Circular Array

An array that wraps around so that the first index follows the last index.

13
New cards

Postfix Expression

An expression where operators follow their operands; easier to evaluate than infix.

14
New cards

Infix Expression

An expression where operators are placed between operands; requires consideration of precedence and parentheses.

15
New cards

Linked List

A data structure consisting of nodes, where each node contains data and a reference to the next node.

16
New cards

ArrayList

A resizable array implementation of the List interface.

17
New cards

LinkedList

A doubly linked node structure that implements the List and Queue interfaces.

18
New cards

Syntax Error Exception

An exception that indicates a syntax error occurred during expression processing.