One thing I love about code is that I can see the structure at a glance; branches and functions stand out, so I can get a mental map of how things are laid out. Obviously it doesn’t make a difference in terms of what the code does, but it makes it much simpler to reason about things.
Case in point.
int a = 10; int b = 20; int c = a + b; if(c < 50) { printf("Expected result.\n"); } else { printf("Something is broken.\n"); }
int a = 10;
int b = 20;
int c = a + b;
if(c < 50) {
printf("Expected result.\n");
}
else {
printf("Something is broken.\n");
}
The two blocks of code do the exact same thing, but the second is far simpler to read. In languages like Python, the code actually has to match a structure closer to the second because it’s easier to read and reason about. What does this have to do with writing though?
Here’s a paragraph from one of my recent short stories.
“Well…we keep all strays in isolation for a few days, just in case they have parasites or something.” I slid my hand to Pinecone’s chest and scratched the tuft of white fur between his front legs. “He came back clean, but one of our vets checked the rest of his litter and found some pretty nasty stuff in their bellies. Strays can’t be picky eat”—my voice caught—“they can’t be picky eaters, and mom found something awful. They all got sick…then they all passed away. The vet said it was would have been painful.” Salty tears slid down my cheeks.
It’s about a half-dozen sentences (mostly dialogue), but it visually looks like a blob. At a glance, I can’t tell where the dialogue begins and ends. I can’t get a feel for how long any of the sentences are. The structure of this paragraph is lost within its content.
Do any of those things matter to a reader? Probably not, since they’re consuming a story the way the author presented it. To authors though…yeah. Even amateurs like me know to mix up sentence length and paragraph style or slip actions in the middle of dialogue to break up things up. One of my bad habits is falling back on the same patterns in dialogue again and again.
- If a paragraph starts with dialogue include a tag to identify the actor.
- Start a paragraph with action to identify the actor and drop the tag.
Easily ninety percent of my dialogue fits one of those patterns. While these are fine guidelines, in long sections of dialogue it starts to feel samey and predictable. If I can see the structure of my writing though, I can (in theory) identify when I’m falling too heavily on these patterns for long stretches.
The same paragraph as above looks like this in my editor is formatted like this.
\enquote{% Well\ldots{}we keep all strays in isolation for a few days, just in case they have parasites or something.% } I slid my hand to Pinecone's chest and scratched the tuft of white fur between his front legs. \enquote{% He came back clean, but one of our vets checked the rest of his litter and found some pretty nasty stuff in their bellies. Strays can't be picky eat% }\textemdash{}my voice caught\textemdash{}\enquote{% they can't be picky eaters, and mom found something awful. They all got sick\ldots{}then they all passed away. The vet said it was would have been painful.% } Salty tears slid down my cheeks.
Now the structure is far more clear. I can see each chunk of dialogue and how it corresponds to the paragraph as a whole. It’s obvious at a glance that my sentence length decreases in the last section of dialogue. The only part of the structure that isn’t clear is the narrator’s voice catching in their throat.
Since I want my narrator to be caught up in their emotions near the end, the shorter sentences make sense. I got lucky while writing the first draft, but on my normal days (when my writing is even worse than usual), now the problems stand out more easily.
So will this magically make writing better? Of course not, just like a nice visual structure can’t make source code magically better. For mortals like me though, I get to reason about aspects of my writing that would otherwise be difficult.