Skip to content

Latest commit

 

History

History
12 lines (9 loc) · 329 Bytes

File metadata and controls

12 lines (9 loc) · 329 Bytes

Implement a stack structure

Create a Python class that implements the methods of a stack structure.

Challenge

Implement the following methods.

  • push add an item to the stack
  • pop remove and return the most recent item from the stack
  • peek return the most recent item from the stack

Solution

Whiteboard Images