Skip to content
blog
2 min read

Think like a developer

Overcome coder's block by breaking problems into smaller tasks. A practical guide to thinking like a developer when you're stuck.

Coder’s block usually isn’t about not knowing enough. It’s about trying to solve the whole problem at once.

The Core Habit: Decompose

When you’re stuck, the question isn’t “how do I build this?” It’s “what’s the smallest piece I can build right now?”

A todo app isn’t one problem. It’s:

  1. Display a list of items
  2. Add an item
  3. Mark an item complete
  4. Delete an item

Each of those is solvable. The whole app just feels big.

Start With What You Know

You don’t need to know the full solution to start. Write the code you’re confident about and let it reveal the next question.

// I know I need an array of tasks
const tasks = [];
// I know I need to add to it
function addTask(text) {
tasks.push({ text, done: false });
}
// What's next? Displaying them. That's the next problem.

Momentum compounds. One solved piece makes the next one clearer.

Name the Gap

When you’re stuck, say out loud what you don’t know:

“I know how to store the task, but I don’t know how to update the DOM when it’s added.”

Now you have a searchable question instead of a vague feeling of being lost. Naming the gap turns a wall into a door.

Don’t Optimize Early

The first version doesn’t need to be clean. It needs to work. Refactor once it works, not before.

A developer who ships messy code and cleans it up is further ahead than a developer who never shipped because the code wasn’t elegant enough to start.