Skip to content
This repository was archived by the owner on Sep 7, 2025. It is now read-only.

Conversation

@skilldeliver
Copy link

Class implementation of the Stack data structure. It has several methods - like push, pop, seek_top, seek_base, clean, etc.

"""
def __init__(self):
# Constructur for the Stack
self.items = list()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can simply write self.items = []

"""
Deletes all items in the Stack.
"""
self.items = list()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same thing as above

@@ -0,0 +1,62 @@

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a main-function with some test cases

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants