Skip to main content

pydatastruct

Educational DSA implementations

Installation

pip install pydatastruct

💡 Usage Examples

Basic Operations

from pylib_datastruct import Stack, Queue, Graph, Tree

# Stack
stack = Stack()
stack.push(1)
stack.push(2)
stack.pop()  # 2

# Queue
queue = Queue()
queue.enqueue(1)
queue.enqueue(2)
queue.dequeue()  # 1

# Graph
graph = Graph()
graph.add_edge("A", "B")
graph.add_edge("B", "C")
neighbors = graph.get_neighbors("A")

# Tree
tree = Tree(5)
tree.insert(3)
tree.insert(7)
inorder = tree.inorder()

AI/ML Use Cases

from pylib_datastruct import Stack, Queue, Graph, Tree

# Use stack for DFS in ML graph algorithms
stack = Stack()
stack.push(start_node)
# Process nodes...

# Use queue for BFS
queue = Queue()
queue.enqueue(root)
# Process nodes...

📚 API Reference

See package documentation for complete API reference.

🤖 AI Agent Friendly

This package is optimized for AI agents and code generation tools:

  • Clear function names and signatures
  • Comprehensive docstrings with examples
  • Type hints for better IDE support
  • Common use cases documented
  • Zero dependencies for reliability

License

MIT

Release files for pylib-datastruct 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pylib-datastruct 0.1.0
File Size Uploaded
pylib_datastruct-0.1.0.tar.gz 2.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pylib-datastruct 0.1.0
File Interpreter ABI Platform
pylib_datastruct-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 4.4 kB

Release files / pylib_datastruct-0.1.0.tar.gz

Download URL pylib_datastruct-0.1.0.tar.gz
Size 2.4 kB
Tags Source
SHA-256 checksum
How to use checksums
2b54b2d28009490c6d71ab8c2afc15103f17cc1f6f511ac29f5335331ae103bf
BLAKE2b-256 checksum
How to use checksums
de8f132e7cd4500db88852af74842d2eaad190ab697296ad1505d3c9f5e7755d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release files / pylib_datastruct-0.1.0-py3-none-any.whl

Download URL pylib_datastruct-0.1.0-py3-none-any.whl
Size 2.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9be765680c732c8827db5d3270d50c57e2bf9261add45d3f0288695acccd1094
BLAKE2b-256 checksum
How to use checksums
9c1473e21a0fc38219d5cbfb348b1806e489e998902d4a66a3ac18548434737b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page