Contributing to DSA
Thank you for considering contributing to our DSA-focused Java project! We welcome contributions that enhance the codebase, improve documentation, add new algorithms, or provide valuable insights. By following these guidelines, you'll help us maintain a high standard of quality and ensure consistency across the project.
- Code of Conduct
- How to Contribute
- Reporting Bugs
- Feature Requests
- Code Contribution Guidelines
- Pull Request Process
- License
Please review and follow our Code of Conduct. We are committed to maintaining a welcoming environment for all contributors.
There are several ways to contribute to this project:
- Fix bugs or improve the existing codebase.
- Add new data structures or algorithm implementations, including Leetcode solutions or interview questions.
- Enhance documentation and improve code readability.
- Suggest new features or improvements related to DSA topics.
Please ensure that any code contributions align with the DSA and Problem-Solving theme of the project.
If you encounter a bug:
- Search for existing issues to check if it’s already been reported.
- If not, create a new issue.
- Provide a detailed description of the issue.
- Include steps to reproduce the problem, if applicable.
- Attach any relevant logs or context that can help us understand the issue.
For suggesting new features or improvements:
- Open a new issue.
- Provide a detailed explanation of the problem you're addressing.
- Describe how your proposed feature fits into the project.
We welcome code contributions! Please follow these guidelines to ensure consistency and maintainability:
- Use descriptive and meaningful names for files that represent the data structure or algorithm implemented.
- Example:
BinarySearchTree.java
,QuickSort.java
- Example:
- Follow standard Java conventions:
- Variables and methods: Use camelCase.
- Classes: Use PascalCase.
- Avoid redundant comments but document complex or non-obvious logic.
- Indentation: Use 4 spaces, no tabs.
- Limit each line to 100 characters.
- Include JavaDocs for all methods and classes.
- Every new data structure or algorithm must have corresponding unit tests.
- Use JUnit 5 (or specify another framework, if preferred).
- Tests should cover both edge cases and expected behavior.
- Write clear and concise commit messages that explain the changes.
- Example:
Added QuickSort algorithm with tests
orFixed issue in LinkedList implementation
.
- Example:
- If your commit addresses an open issue, reference the issue number.
To submit your contributions, follow these steps:
- Fork the repository and create a new branch for your feature or bug fix.
- Naming convention for branches:
feature/algorithm-name
orfix/issue-description
.
- Ensure no existing functionality is broken by running tests before submitting your PR.
- Submit a pull request (PR) with:
- A clear description of the changes.
- References to relevant issues, if applicable.
- Your PR will be reviewed, and feedback may be provided. Please be responsive to review comments and adjust your PR accordingly.
By contributing to this repository, you agree that your contributions will be licensed under the terms specified in the LICENSE file.