How to Solve Logic Puzzles With Microsoft Excel

by mtairymd in Teachers > 8

2509 Views, 2 Favorites, 0 Comments

How to Solve Logic Puzzles With Microsoft Excel

10.JPG

You have most likely seen this type of puzzle pop across your online feed. Some are simple enough that you can figure them out in your head. However, as the number of equations increases, the challenge becomes harder. This short tutorial shows you an easy way to solve this type of puzzle using Microsoft Excel. Note that these instructions are for MS Office 2016 but the same logic applies to newer versions of Excel.

Solver Add In

2.JPG
3.JPG

Open Excel

Add-ins provide optional commands and features for Microsoft Excel. By default, add-ins are not immediately available in Excel, so you must first install and (in some cases) activate these add-ins so that you can use them.

To enable, do the following:

  • Click the File tab, click Options, and then click the Add-Ins category.
  • In the Manage box, click Excel Add-ins, and then click Go.
  • The Add-Ins dialog box appears.
  • In the Add-Ins available box, select the check box next to the add-in that you want to activate. For this exercise, you want to select Solver Add-In. Click OK.



Solver Location

4.JPG

Now that you have installed the add-in, you must access it. From the Main Screen, go to the Data tab. The Solver should be included in the Analysis subsection.

Setting Up the Problem

7.JPG

Before writing equations, it is often easier to assign variables to the items. This makes it easier when writing the equations. I used the values shown in this image.

Adding Data to Excel

5.JPG

Now it's time to enter the data into Excel. Each line from the introduction picture will be added to the spreadsheet. Column E shows the equations in text format. This step isn't needed but I thought it would help with understanding the process. Column F shows the equations in Excel. Column G is the total from each line (see intro picture). Enter data exactly as shown.

Solver

6.JPG

You are now ready to net up the solver. Click the Solver icon (Data => Solver) from Step 2. This will bring up a solver panel.

  • Start by setting the Set Objective to Cell $F$3. For the To value, set the Value Of to 29. This sets both sides of the equation equal to each other.
  • Next, set the By Changing Variable Cells to $D$3:$D$9. This column will fill out during the solving process.
  • Click Add
  • Repeat the process for the remaining equations as shown.
  • You have now filled out all the information required to solve the puzzle.
  • To run the solver, click on Solve

Give It a Shot

Question.jpg

Did it work? Please comment if you have any questions.