Microsoft Excel is a ridiculously powerful spreadsheet program, and you can do more than just track data in it. It has a ton of macros, a programming language called VBA (that I'd argue is akin to an Object Oriented Programming language, though not in a similar way to Java or C#), and a lot of powerful functions. As an example of Excel's strength, a Reddit user even made a Sudoku solver using just Excel, and how it works is magnificent.

👁 A guide on making interactive dashboard in Excel
How you can make interactive dashboards in Microsoft Excel (and why you should)

Transform your data into insights by harnessing the power of pivot tables to make interactive dashboards

By  Parth Shah

Excel is incredibly powerful

A weird, but practical way to solve Sudoku puzzles

Back in 2020, Reddit user /u/KrakenOfLakeZurich created a Sudoku solver in Microsoft Excel. It only uses formulae and conditional formatting, and it's available for both Excel and LibreOffice Calc. One example function that the user shows off is the following:

one_to_nine: =MOD(COLUMN(Sudoku!A1)-1, 3) + 1 + MOD(ROW(Sudoku!A1)-1, 3) * 3 The above formula is used to map one cell from a 9x9 Sudoku grid to one of the positions within a smaller 3x3 sub-grid. In Sudoku the larger grid is divided into nine smaller 3x3 grids and each cell needs to be placed within those smaller grids. The formula takes the row and column numbers of a specific cell (A1 in the above example) and performs calculations in order to figure out which position (from 1 to 9) it belongs to within its respective 3x3 sub-grid.

It does this via the MOD function, which calculates the remainder when dividing the row and column numbers by 3. This can then identify the cell's position within the 3x3 grid, and the formula combines the results from both row and column to give a single number. This single number represents the position within the sub-grid. It's a pretty complex formula, but gives you an idea of just how powerful Excel is.

👁 How to use Copilot in Excel
5 ways to up your Excel game with Microsoft Copilot

Essential tricks to transform your Excel workflow with Microsoft Copilot

By  Parth Shah

Solving a Sudoku puzzle with Excel

Number by number

Solving a Sudoku puzzle with this spreadsheet is fairly simple. The board in the top left is the input board, the board in the bottom left are the solutions it calculates as you enter numbers, and the large board is a calculation board. The calculation board shows all of the possible values that can fit into a cell, and when there is only one possible value left, this value is then represented in the calculation board in black.

Avid Sudoku fans might be aware that some puzzles will require you to make guesses and potentially backtrack if those guesses are wrong. In those instances, you should look for a cell that has the fewest possible answers, and then go ahead with entering that number into the input board. If it solves, great, but if you hit a wall where it can no longer calculate anymore, backtrack and go for the other number.

While this is a practical application for solving Sudoku puzzles, it's practical in the sense that someone can learn a lot about Excel from it. There are countless Sudoku solvers out there that don't require consistent manual input, but they're nowhere near as fun as an application like this that can stretch the limits of what you thought was possible in Excel. In truth, this only scratches the surface, especially with the recent integration of Python with Excel!