Solving the Game Quartiles

Today I noticed that there was a new game on Apple News+ called Quartiles. I solved one puzzle on my own, then I realized Keyboard Maestro could get me a better answer. So I took an hour to write the code. The code solves the problem in 15 minutes. I'll post code fragments here. The reason I'm doing this is because I'm not sure if I'm allowed to share the English dictionary that I obtained from the Internet, so that part you may have to resolve yourself.

Step 1 - Read the 20 quartiles from the screen in the News+ App. And then have the user validate that they are correct. If you know how to save an image in a clipboard, you can trigger this macro using "Clipboard Change Filter" or you can find some other way to place the 20 words into an image and then into the clipboard. These actions will use OCR to convert the image to a variable called "Words".

image

Step 2 - Set a variable, "WordList" to an empty string. This is where all candidate words will be stored.

image

Step 3 - Prepare a dictionary into a variable called LocalDictionary and place in it an alphabetically sorted list of all English words. You may have to get such a list from the Internet as it does not seem to be available in macOS.

Step 4 - Run this loop. This will form all combinations of quartiles. (You should probably turn on the Progress Bar on Loop1.

image

Step 5 - Sort the candidate word list, and remove duplicate values. (My program can be modified by two additional actions to remove duplicates, but that makes my program take 5 times longer. It's very easy to notice duplicates at the end manually, if there are any, so the extra time isn't worth it.) Pick your own filename.

image

Step 6 - Make sure your sorted dictionary is stored in a file, perhaps like this:

image

Step 7 - Find the common words. Problem solved. If you see any items using repeated quartiles, you can ignore them. There probably won't be any.

image

It took 15 minutes for my program to run. Your results may differ. But 15 minutes is about the same amount of time as it takes to solve the puzzle, so you won't have to wait long if you start it up when you start doing the puzzle.

The purpose of this program isn't to help you cheat, it's to see all the correct answers at the end, which the puzzle didn't give me.

Some people have WAY too much time on their hands. :joy:

That doesn't mean I wouldn't have tried to do the same thing, of course. :wink:

I worked hard to earn my free time. As you probably did.

1 Like

Darn right we did!!!