Data Structures & Algorithms in Java: Working with Stacks


Overview/Description
Expected Duration
Lesson Objectives
Course Number
Expertise Level



Overview/Description

The stack in Java allows us to access data in a last in, first out manner and in the best case scenario, both of these operations are performed in constant time. In this course, you'll get started by examining the behavior and characteristics of the stack data structure. The stack is often referred to as LIFO - or last in, first out - since the last element that you push on to a stack is the first element that you access. You'll learn how you can implement the stack data structure using arrays and linked lists and how to assess the trade-offs between these two implementations. Lastly, you'll see how to write code to perform common operations on a stack such as push(), pop(), and peek() and how to assess the running time for each of these operations.



Expected Duration (hours)
1.5

Lesson Objectives

Data Structures & Algorithms in Java: Working with Stacks

  • discover the key concepts covered in this course
  • recall the basic characteristics of the stack data structure
  • perform simple operations on a stack implemented using arrays
  • push new elements on to a stack implemented using arrays
  • pop elements from a stack implemented using arrays
  • peek into a stack implemented using arrays
  • push new elements on to a stack implemented using linked lists
  • pop elements from and peek into a stack implemented using linked lists
  • set up the basic interface for the Command object
  • implement undo using stacks and the Command object
  • check for well formed arithmetic expressions using stacks
  • find the minimum element in constant time in a stack
  • summarize the key concepts covered in this course
  • Course Number:
    it_jddsajdj_04_enus

    Expertise Level
    Intermediate