One of the most useful aspects of using a programming language instead of… well, not using a programming language, is that you can write code in a way that minimizes, and ideally, eliminates the need to repeat yourself.
For instance, you can write a function to show you a frequency table, like so:
<pre …