Data Structures and Algorithms implemented in Python
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
README.md
binary_search.py
binary_search_recursive.py
binary_search_tree.py
binary_tree.py
bubble_sort.py
deque.py
deque_palindrome_checker.py
hash_table.py
insertion_sort.py
linked_list_ordered_singly.py
merge_sort.py
queue.py
queue_hot_potato.py
quick_sort.py
selection_sort.py
shell_sort.py
short_bubble_sort.py
stack.py
stack_paren_checker.py

README.md

Data Structures & Algorithms in Python

Implementations and study notes are based on Problem Solving with Algorithms and Data Structures using Python


Data Structures:

  • stack.py - Implementation of the "Stack" data structure.

  • queue.py - Implementation of the "Queue" data structure.

  • deque.py - Implementation of the "Deque" data structure.

  • linked_list_ordered_singly.py - Implementation of a ordered singly "Linked List" data structure.

  • hash_table.py - Implementation of a "Hash Table" data structure that uses a simple "remainder method" (key % table_size).

  • binary_tree.py - Implementation of a "Binary Tree" data structure. It includes preorder, postorder and inorder traversals.

  • binary_search_tree.py - Implementation of a "Binary Search Tree" data structure. It highlights how to create a python "Class" that implements a container object, such as a list or dictionary.

Algorithms:

Examples:

  • stack_paren_checker.py - Function that assumes that a Stack class is available and returns a boolean result as to whether the string of parentheses is balanced.

  • queue_hot_potato.py - General simulation of the children's game "hot potato" that makes use of the Queue data structure.

  • deque_palindrome_checker.py - This function uses the Deque data structure and takes input as a string of characters to check whether it is a palindrome.