Skip to content

bernardev254/dsa-4-thinking

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DSA Practice Repository

Welcome to the DSA Practice Repository! This repository is dedicated to honing your problem-solving skills in Data Structures and Algorithms (DSA). Our approach here is centered around the idea that writing is thinking, especially when it comes to tackling complex DSA problems.

Thinking Before Coding

Why Write First?

In this repository, we prioritize the process of understanding and articulating your thoughts before diving into code. Writing out your approach helps you break down the problem, consider edge cases, and formulate a clear strategy. It's about developing a structured thought process and making your solutions more robust.

How to Practice

  1. Understand the Problem:

    • Read the problem statement thoroughly.
    • Identify the input, output, and constraints.
  2. Brainstorm and Write:

    • Before coding, articulate your thoughts in writing.
    • Describe your understanding of the problem.
    • Outline a high-level strategy or algorithm.
  3. Consider Edge Cases:

    • Think about potential edge cases and tricky scenarios.
    • Document how your solution handles these cases.
  4. Pseudocode:

    • Write pseudocode to outline the logical steps of your solution.
    • This helps in transitioning from high-level thinking to code.
  5. Write Tests:

    • Before implementing, consider writing test cases.
    • This helps validate your solution and ensures it works as expected.
  6. Iterate:

    • Don't hesitate to revisit and revise your written plan as needed.
    • Iterate through steps 1-5 until you are confident in your approach.

Repository Structure

This repository is organized into sub-repositories, each containing specific DSA problems. Within each sub-repository, you'll find:

  • problem-description.md: A detailed description of the problem.
  • your-solution.py (or other programming languages): A template for you to fill in your code.
  • solution-explanation.md: Your written explanation of the solution.

Contributing

  1. Fork this repository.
  2. Create a new branch: git checkout -b feature/new-problem.
  3. Follow the thinking-before-coding approach outlined above.
  4. Implement your solution and document your thought process.
  5. Submit a pull request.

Remember, the goal is not just to solve problems but to enhance your problem-solving skills through thoughtful analysis and clear articulation. Happy coding!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages