HACKER Q&A
📣 rewgs

How do you go about planning your code?


An oft-repeated phrase I see on HN from time to time is something to the effect of "one should spend more time planning/designing/architecting/etc than writing code." The more experience I've gained, the more I've come to appreciate the wisdom in this.

My planning/designing/architecting is all pretty much pencil and paper. That's perfectly fine, but I'm wondering if I'm missing out better tools and workflows.

So, those who follow the above quote: How do you go about doing it? What tools do you use? What's your workflow like?


  👤 wruza Accepted Answer ✓
Not sure if I follow it, because spending too much time there usually postpones discovering a “sudden truth in code” which may refactor the half of what you planned. I prefer to dive into code midway. Prove my assumptions with MVP first.

I didn’t invent nothing better than pen and paper, despite searching for years. Software gets in my way, pen doesn’t. The only thing I adopted is text outlining. It’s basically text structured as a tree.

  Tools for planning and design
    Pen and paper (don’t get in your way)
      Searched for alternatives for years
    Text outlining
      Text structured as a tree
      Useful when tired of writing
      Useful for non-linear thinking/planning
My pen and paper workflow is mostly freehand non-strict diagrams and mindmaps, then later tasks with circles and various marks for completion status. I draw a little box in a corner and put the kind of a paper there: arch if architectural, plan for high-level plans, nothing for tasks. Makes easy search when in a stack.

I tried scanning these papers. Nope, even reading them on screen doesn’t work for me.


👤 hardkorebob
Wish I could type helpful words. I am learning myself how to do this.