Skip to main content

Data Structure Package By Pappalaity

Project description

๐ŸŒฟ Laity Data Structures

Version Python License

Laity Data Structures is a Python package that provides simple and educational implementations of essential non-primitive data structures such as stacks, queues, linked lists, and binary search trees.

Whether you're a student, a developer preparing for interviews, or someone curious about how data structures work under the hood โ€” this package is for you.


โœจ Features

  • โœ… Easy-to-read Python code
  • ๐Ÿงฑ Stack, Queue, Linked List, Binary Search Tree implementations
  • ๐Ÿ“˜ Educational method names and documentation
  • ๐Ÿ“ฆ Simple pip installation
  • ๐ŸŽ“ Ideal for learning & teaching
  • You can check the documentation website

๐Ÿ“ฆ Installation

pip install laity-data-structures

Once installed, you can import any class into your project:

from laity.stack import Stack

s = Stack()
s.push(10)
s.push(20)
s.display()  # Output: [10, 20]

๐Ÿงฐ Data Structures Included

๐Ÿ” Stack

A Last-In, First-Out (LIFO) linear data structure.

stack.push(value)
stack.pop()
stack.peek()
stack.is_empty()
stack.size()
stack.display()

๐Ÿ“ค Queue

A First-In, First-Out (FIFO) linear structure for sequential data processing.

queue.enqueue(value)
queue.dequeue()
queue.peek()
queue.rear()
queue.is_empty()
queue.display()

๐Ÿ”— Singly Linked List

A series of nodes connected using pointers. Efficient for insertions and deletions.

linked_list.insert(value)
linked_list.insertAtBeginning(value)
linked_list.insertAfter(index, new_value)
linked_list.delete(value)
linked_list.search(value)
linked_list.traverse()
linked_list.display()

๐ŸŒณ Binary Search Tree (BST)

A hierarchical structure where each node has at most two children. Left child < node < right child.

bst.insert(value)
bst.search(value)
bst.printInOrder()
bst.printPreOrder()
bst.printPostOrder()

๐Ÿ“‚ Project Structure

laity-data-structures-py/
โ”‚
โ”œโ”€โ”€ laity/
โ”‚   โ”œโ”€โ”€ stack.py
โ”‚   โ”œโ”€โ”€ queue.py
โ”‚   โ”œโ”€โ”€ linked_list.py
โ”‚   โ”œโ”€โ”€ tree.py
โ”‚
โ”œโ”€โ”€ examples/
โ”‚   โ”œโ”€โ”€ stack_test.ipynb
โ”‚   โ”œโ”€โ”€ queue_test.ipynb
โ”‚   โ”œโ”€โ”€ linked_list_test.ipynb
โ”‚   โ”œโ”€โ”€ tree_test.ipynb
โ”‚
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ setup.py
โ””โ”€โ”€ LICENSE

๐Ÿค Contributing

Contributions are welcome! Here's how you can help:

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

๐Ÿ“œ License

This project is licensed under the MIT License โ€” see the LICENSE file for details.


๐Ÿ™Œ Acknowledgements

Created with โค๏ธ by PappaLaity
Inspired by educational goals and the love of clean, simple code.


๐Ÿš€ Ready to Explore?

Install it, play with it, modify it โ€” and level up your understanding of data structures one line at a time.

pip install laity-data-structures

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

laity_data_structures-0.1.4.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

laity_data_structures-0.1.4-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file laity_data_structures-0.1.4.tar.gz.

File metadata

  • Download URL: laity_data_structures-0.1.4.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for laity_data_structures-0.1.4.tar.gz
Algorithm Hash digest
SHA256 6f4045098b7848b0fb8a97bd8275eb62f6074f7378d0df52bfab7625d84a5c95
MD5 edabf882652a7ef585fd2adb315cc1ea
BLAKE2b-256 646d2b9e8aecfd9569e35d624aa43f5827e6f7a2e7560d36e475c27432f0c006

See more details on using hashes here.

File details

Details for the file laity_data_structures-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for laity_data_structures-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 100128a5f9450da0e8cce1465a0676a05f66a8f3e36b8473240d86e26212d522
MD5 8a7c1dfed3e18630dc8b873ee070826c
BLAKE2b-256 dd2b59d6a0590e795dfc41fe4416efda3a6e9dfd051f9b6ff22b93f43a5e78be

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page