kelvins / algorithms-and-data-structures

:abacus: Algorithms and Data Structures in several Programming Languages
MIT License
1.04k stars 256 forks source link

update queue.py #337

Closed MrWeast closed 9 months ago

MrWeast commented 9 months ago

changed implementation to not use built in python lists. added English comments

Description

Previous implementation used built in python lists which seems counter to the point of implementing a queue data structure since python lists already support queue functionality. I also added English comments since there is an open issue about that (#183).

New Queue:

To test the implementation you can run the file since it includes test cases in the main function of the file