Search for a tool
Lights Out Solver

Tool/solver to resolve the Lights Out levels, a puzzle game based on a change of state/color of the cells of a grid (and its neighbours).

Results

Lights Out Solver -

Tag(s) : Mobile Games

Share
Share
dCode and more

dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!


Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!


Thanks to your feedback and relevant comments, dCode has developed the best 'Lights Out Solver' tool, so feel free to write! Thank you!

Lights Out Solver

Lights Out Grid Solver


Loading...
(if this message do not disappear, try to refresh this page)

Answers to Questions (FAQ)

What is the rule of the Lights Outs game?

Lights Out is an electronic game composed of a grid of lighted (sometimes with bulbs) or numbered cells (originally 5 by 5).

At the start of the game, a pattern of cells is lit (different states). By pressing one of the boxes, it switches state (it goes from on to off, or from off to on or changes color), as well as the four adjacent boxes (neighboring top, right, bottom and left).

The goal of the game is to switch all the lights to the off (or on) position, preferably by pressing as few boxes as possible.

Example: A game board with 2 states: 0 or 1 is in the initial position:

000
000
000

A click on the middle box gives the following result:

010
111
010

(the box clicked as well as the 4 adjacent cells (top, bottom, right, left) have changed state)

How to solve a Lights Outs grid?

The principle of resolution is mathematical, by modeling the grid by a matrix $ [a_i] $ of size $ n \ times m $ and $ p \ geq 2 $ possible states.

By pressing a box, some other cells have their state changed or reversed (if $ p = 2 $)

The next state is then determined, for each box $ i $, by the number of times the boxes are pressed (modulo $ p $)

This state can be represented with $ m $ calculations $ a_ {i1} x_1 + ... + a_ {in} x_n) \ mod p = 0 $ for which the value of $ x_i $ is the solution sought.

Source code

dCode retains ownership of the online 'Lights Out Solver' tool source code. Except explicit open source licence (indicated CC / Creative Commons / free), any 'Lights Out Solver' algorithm, applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, translator), or any 'Lights Out Solver' function (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) and no data download, script, copy-paste, or API access for 'Lights Out Solver' will be for free, same for offline use on PC, tablet, iPhone or Android ! dCode is free and online.

Need Help ?

Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!

Questions / Comments

Thanks to your feedback and relevant comments, dCode has developed the best 'Lights Out Solver' tool, so feel free to write! Thank you!


Source : https://www.dcode.fr/lights-out-solver
© 2021 dCode — The ultimate 'toolkit' to solve every games / riddles / geocaching / CTF.
Feedback