Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

empty_board

Initialize a Lights Out board with all lights switched off


Description

Initialize a Lights Out board with all lights switched off

Usage

empty_board(size, classic = TRUE)

Arguments

size

Number of rows and columns for the board

classic

If TRUE, then pressing a light will toggle it and its adjacent neighbours only. If FALSE, then pressing a light will toggle the entire row and column of the pressed light.

Value

A lightsout board.

See Also

Examples

empty_board(5)

lightsout

Implementation of the 'Lights Out' Puzzle Game

v0.3
MIT + file LICENSE
Authors
Dean Attali [aut, cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.