Skip to primary content
Skip to secondary content

C For Dummies Blog

Main menu

  • C For Dummies (home)
  • History
  • Series
  • Supplemental
  • Blog Miscellany

Author Archives: dgookin

Post navigation

← Older posts
Newer posts →

Hunting for 7-Character Pangrams

Posted on November 18, 2023 by dgookin
4

I’m a fan of the online game Spelling Bee. In this game, you use a combination of seven letters to spell various words. Each word is at least four-letters long and must contain a special letter, shown in the center of Figure 1. When you create a word that contains all seven letters, you’ve discovered a pangram.
Continue reading →

Posted in Lesson | 4 Replies

Finding Four-Letter Words

Posted on November 11, 2023 by dgookin
2

Not all the nasty words are four letters long, but a good chunk of them are. If you ran the program from last week’s Lesson, you can quickly check the computer’s dictionary for the words you once couldn’t say on TV, gleefully typing them in and confirming that they exist in the dictionary. But how many four letter words are there?
Continue reading →

Posted in Lesson | 2 Replies

Numbers with Unique Digits – Solution

Posted on November 8, 2023 by dgookin
1

I hope you came up with an interesting solution for this month’s Exercise, one different from my own. The goal is to output unique values from zero through ten billion, values where no two digits repeat.
Continue reading →

Posted in Solution | 1 Reply

Checking Your Spelling

Posted on November 4, 2023 by dgookin
Reply

At the basic level, a spell-checker works as a simple comparison program: The word in question is compared with each word in the dictionary. When the source word isn’t found, it’s assumed to be misspelled. With a dictionary file on your computer, it’s easy for a C programmer to code this type of program.
Continue reading →

Posted in Lesson | Leave a reply

Numbers with Unique Digits

Posted on November 1, 2023 by dgookin
Reply

Difficulty: ★ ★ ★ ☆

I’m sure some eccentric term exists to describe a number where no digits repeat. Whether this concept has any mathematical relevance remains uncertain. But it’s the type of problem you can easily solve by writing a computer program.
Continue reading →

Posted in Exercise | Leave a reply

Plucking Out a Random Word

Posted on October 28, 2023 by dgookin
Reply

It’s time for your computer to babble nonsensically. No alcohol is necessary. All you must do is pluck out a random word from the dictionary. Run the program several times and you have babbly nonsense: subtotal spectacles lute's sushi's. Brilliant! *HIC*
Continue reading →

Posted in Lesson | Leave a reply

Finding the Long Words

Posted on October 21, 2023 by dgookin
Reply

Beyond knowing how many words are in the computer’s dictionary, another good measure to know is how many characters are in the longest word. Together, these two values give you a profile for the complete word matrix.
Continue reading →

Posted in Lesson | Leave a reply

Reading the Dictionary

Posted on October 14, 2023 by dgookin
Reply

I admit it: I’m a nerd and I read the dictionary. I know it’s a reference, not a work of fiction. The plot is weak. But I found it enjoyable as a kid to discover new words and their meanings. Alas, the Unix dictionary file lists only words and not definitions. But how many words are in there?
Continue reading →

Posted in Lesson | Leave a reply

Coin Flipping Madness – Solution

Posted on October 8, 2023 by dgookin
Reply

I hope you didn’t “flip out” over this month’s Exercise. Flipping a coin can be done by hand or by using a computer. Using a computer is easier because it can be programmed to record each flip and it saves you hand muscle molecules for flipping and the chore of writing down the results.
Continue reading →

Posted in Solution | Leave a reply

Finding the Dictionary

Posted on October 7, 2023 by dgookin
Reply

My first Unix System Administrator job was pretty routine: I did backups. It was only later that I discovered some of the many nerdy treasures available in that operating system.
Continue reading →

Posted in Lesson | Leave a reply

Post navigation

← Older posts
Newer posts →

Recent Posts

  • Dumping the Screen in W-I-D-E Color
  • Which is Greatest? – Solution
  • Dumping the Screen in Color
  • Which is Greatest?
  • Consistently Constant

Recent Comments

  • dgookin on Dumping the Screen in W-I-D-E Color
  • M.Stumpfl on Dumping the Screen in Color
  • Chris Webb on Dumping the Screen in W-I-D-E Color
  • Chris Webb on Dumping the Screen in Color
  • M.Stumpfl on Dumping the Screen in Color

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Copyright © 1997-2025 by QPBC.
All rights reserved

Proudly powered by WordPress