Priority Queues
Create a Queue that Supports Data Priority
Exploration
Read chapter 19 in A First Course on Data Structures in Python Explore PriorityQueue
implementations in theds2
package of donsheehy/datastructures. Can you write tests to confirm that they preserve priority? Can you see how this data structure combines those that we previously studied?Review previous chapters to see how the data structures like List
,Queue
, andTree
support the behavior of this data structure.
Activities
Tuesday and Thursday: Priority Queues - Explore how to implement the
PriorityQueue
data structure - Understand how the
List
andTree
support implementing thePriorityQueue
- Explore how the
Heap
can be used to implement thePriorityQueue
- Examine Python source code segments to illustrate key points
- Explore how to implement the
Friday: Submit algorithm engineering project six, start algorithm engineering project seven, and prepare for the algorithm engineering skill-check next week
Project
Goal
To build and use a Python program, called treeprocessor
, that runs benchmarks to study the performance of finding data values in a hierarchical data structure.
Steps
- Click the link provided in Discord to get started on this project
- Use
Tree Processor as your template repository - Install the project’s dependencies using
devenv
and/orpoetry
- Follow the instructions to complete the project:
- Week 1: Implement all of the modules in
treeprocessor
- Week 2: Design and conduct experiments and document experimental results
- Week 1: Implement all of the modules in
- Schedule office hours if you have questions