Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Completing last part of DataStructure task with RB-Tree model #8

Merged
merged 2 commits into from
Dec 3, 2024
Merged

Conversation

m4tveevm
Copy link
Owner

@m4tveevm m4tveevm commented Dec 3, 2024

This pull request includes multiple changes across various files to improve the codebase, including renaming files, updating imports, adding new functionalities, and configuring project settings. The most important changes include the introduction of a Red-Black Tree implementation, updates to the project structure, and the addition of configuration files for project dependencies and formatting.

Project Structure and Configuration:

  • setup.py: Added a new setup script to define the package distribution for algo_labs.
  • .idea/etu_algo_labs.iml: Updated project configuration to exclude the .venv folder and set the JDK to Python 3.12.
  • pyproject.toml: Added configuration for the black code formatter, specifying line length, target version, and excluded directories.

Code Refactoring and Improvements:

  • src/ShuntingYard/solution.py and related files: Renamed files and updated imports to follow a consistent naming convention and directory structure. [1] [2] [3] [4] [5] [6]
  • README.md: Updated import statements in the example code to reflect the new directory structure.

Red-Black Tree Implementation:

  • src/tree/red_black_tree.py: Added a new Red-Black Tree implementation, including methods for insertion, deletion, rotation, and traversal.
  • src/tree/nodes.py: Introduced abstract and concrete classes for tree nodes, including TreeNode and BinaryTreeNode.
  • src/tree/main.py: Added a script to demonstrate tree traversals and build a Red-Black Tree from a binary tree.
  • src/tree/parser.py: Implemented a parser to build a binary tree from a string representation.
  • src/tree/binary_tree.py: Added a BinaryTree class with methods for traversal and deletion.

These changes improve the project structure, enhance the functionality with a new data structure, and ensure consistent code formatting and configuration.

Copy link

github-actions bot commented Dec 3, 2024

Qodana Community for Python

2 new problems were found

Inspection name Severity Problems
PEP 8 naming convention violation ◽️ Notice 2

☁️ View the detailed Qodana report

Contact Qodana team

Contact us at [email protected]

@m4tveevm m4tveevm merged commit b1242a7 into main Dec 3, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant