“Writer’s Block” is a real thing, but “Programmer’s Block?” According to computer science professor at Oregon State University, Heather Knight, programmers are just as subject to getting blocked as writers, but programmers do not have a host of self-help resources with insights applicable to programming. However, she discovered that many of the writing books for writer’s block had methods that can be applied to programming.
SD Times summarized her list of 10 ways to solve programmer’s block (and yes, her list starts at zero):
Tip 0 (Program First): Schedule your programming like you would a meeting. Do whatever it takes to “glue” yourself to your chair. Grab some coffee and park it.
Tip 1 (Don’t be afraid to use paper): According to Knight, Writing Your Dissertation in Fifteen Minutes a Day “emphasizes the importance of getting to draft zero, the conceptual template predates the first draft.” Sometimes free writing can help grab all those ideas floating around in your head overnight and during the wee hours of the morning. Don’t be afraid to get out the old fashioned pen and paper.
Tip 2 (Establish a programming addiction): Establishing a schedule is the best way to guarantee accomplishment, said Knight. We are creatures of habit after all, so make programming a part of your daily schedule and then set achievable (reasonable) goals.
Tip 3 (Track ideas as well as bugs): Just like you would track bugs, track those ideas as well. Start with Tip #2, but if creativity doesn’t follow your schedule, catch your ideas when you can, said Knight. She recommends carrying a notebook.
Tip 4 (Make friends): Join online forums, meetups, hackathons — chat with folks about their code. According to Knight, “people do better when we have accountability.”
Tip 5 (Learn from others): “Unlike writing, it’s very much encouraged to use pre-existing libraries and samples to scaffold your project needs,” wrote Knight. “Reference where things come from, but there’s no need to re-invent the wheel when someone has already figured a problem out.”
Tip 6 (Be nice to your muse): Like writing, conceptualizing how code should be structured requires a creative process. Take a walk, pace the hallway, and don’t be afraid to “celebrate the activities that fertilize the soil before planting, and water it after,” wrote Knight.
Tip 7 (Be heartless, but not mean-spirited): Stephen King once said writers in their editing stage will “kill their darlings.” For programmers, the tricky part is finding mistakes without recrimination, said Knight. She recommends being heartless when it comes to the purpose of your code, but be kind when it comes to yourself.
Tip 8 (Beware the curse of knowledge): “One of the biggest challenges of writing is ensuring the audience follows,” wrote Knight. “Use whitespace, comment your code, and spend time creating sensible abstractions and structures. It doesn’t matter how clever your prose (or code) is, if people cannot deconstruct the story.”
Tip 9 (End on a downward slope): Knight said to devote 10% of the end of your day to think about what you’ll do the next. That way, you can wake up and just get started on your code. “I believe these ten strategies can make you more creative, more productive, and less likely to get stuck,” she wrote.