Skip to content

Instantly share code, notes, and snippets.

@idlehands
Created May 25, 2013 22:09
Show Gist options
  • Save idlehands/5650941 to your computer and use it in GitHub Desktop.
Save idlehands/5650941 to your computer and use it in GitHub Desktop.
Write a script that loads the file attached and counts the occurrence of each word and lists the 10 most common words. If you feel like doing a little more work, remove "common words" (your judgement, but I mean words like it, the, and and) from the list. HINT: You should use a hash to keep track of your counts. Arrays will likely be used to sol…
When is it okay to have repeating words or phrases, and when is it most definitely not? The distinction is an important element in your writing style.
Now, of course, I’m talking about repeating specific words, the key words of the sentence or paragraph. I’m not talking about repeating words or phrases such as, “It is,” or “and the”.
To give you a good example of what I mean, read the following:
When I got to the bottom of the stairs, I saw that the stairs were high and steep. I took a deep breath and began to climb the stairs. When I reached the top of the stairs I looked around me.
You’ll note of course that the word stairs was used four times in a short paragraph. It just doesn’t sound right to do that - it grates somehow. When you come across this in your work, you need to change it.
So, the above paragraph would be better written as something like:
When I got to the bottom of the stairs, I saw that they were high and steep. I took a deep breath and began to climb the steps. When I reached the top I looked around me.
You’ll note how much better that reads. (Still not wonderful prose, of course, but this was just a quick example.) I took out the word ‘stairs’ twice, and replaced it with a synonym once, i.e. ‘steps’.
There is, of course, a time when repeating words or phrases is fine, and that’s when it’s done for effect. Take as an example the from the opening page of my novel Looking Good. The situation is that Grainne has gone to the doctor fretting because she isn’t conceiving.
[The doctor said] “Remember the number-one trick for conceiving . . .”
“What’s that?” I asked eagerly.
" Relax about it all.”
Relax ! Easy for her to say. And she was insisting I wait another six months!
I felt like wailing at her, ‘It’s not fair !’. A mature reaction, I know. But honestly, it didn’t seem fair.
All around me, everyone we knew was getting pregnant at the drop of a hat. Well, the drop of trousers more like.
Okay, I’d better qualify that. To be honest, not everyone we knew was getting pregnant . Certainly a lot of our friends - mostly the female ones - were getting pregnant and admitting when I challenged them that, yes, it had happened quite quickly, thanks.
The word ‘relax’ is repeated - the character is deliberately echoing what the doctor said, so that works.
The phrase ‘getting pregnant’ is also deliberately repeated for effect.
And likewise the phrase ‘drop of a hat/drop of trousers’ is done for effect. (As an aside, this can be a good use of clichés - as humour, by playing with them and changing them.)
And finally, the repeat of the word ‘fair’ was also a deliberate use of the word.
I hope you can see the difference between my two examples, between the wrong way of repeating words or phrases, and the right way. It’s almost a matter of ‘ear’ to know which works. Which sounds right?
The first example sounds clunky and boring; the second (I hope!) sounds melodic and dramatic.
A terrific resource for finding repeating words or phrases is AutoCrit. (It also catches your clichés for you.) You can use it in a limited way for free. Another free resource is www.wordcounter.com.
In summary, if you have repeating words or phrases, make sure it’s because you want them there and they add to the melody of your work. If they’re clunky and only there because they snuck in, then you need to change them.
@rttong
Copy link

rttong commented May 25, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment