A library of algorithms and data structures for competitive programming
Project description
Competitive Programming Library
A comprehensive library of algorithms and data structures commonly used in competitive programming.
Installation
You can install the package using pip:
pip install competitive-programming-lib
Usage
Here's a quick example of how to use some of the algorithms:
from competitive_programming_lib import CompetitiveProgrammingLib as cpl
# Dijkstra's Algorithm
graph = {
0: {1: 4, 2: 1},
1: {3: 1},
2: {1: 2, 3: 5},
3: {}
}
distances, predecessors = cpl.dijkstra(graph, 0)
print("Shortest distances from node 0:", distances)
# More examples...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for competitive-programming-lib-0.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 003ac58a353e54248a9c6928bd34326c49ea2e222709b5a4afe4380b3cb675de |
|
MD5 | 3e3bef85f61d234fd8baa51e02aadb3a |
|
BLAKE2b-256 | 9021a7b371ac83a03cacb80c939d0e423b62f6d0e011387330ffb43a0124de6d |
Close
Hashes for competitive_programming_lib-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 55c520ccf4d58b18e3938dcdbd34fd506199d5bd1863c0a786bf9b71850fc3f5 |
|
MD5 | 17ca47368455fece67538030f5231deb |
|
BLAKE2b-256 | 6c04aa291407733f8f066db352c26747b30d754cf35aca1f7412d77cae38e266 |