Logo
Overview

Supercells

April 10, 2024
1 min read

What is a Supercell?

In a grid of numbers, a cell is called a Supercell (or is “coloured”) if the number inside it is larger than numbers in all adjacent cells.

  • 1D (Row) Case: Check left and right.
  • 2D (Grid) Case: Check top, bottom, left, and right.

Example

Consider the following row: 200577626345790694109198200 \quad 577 \quad 626 \quad 345 \quad 790 \quad 694 \quad 109 \quad 198

Let’s check specific numbers:

  1. 626: Neighbors are 577577 and 345345. Since 626>577626 > 577 AND 626>345626 > 345, 626 is a Supercell.
  2. 200: Neighbor is 577577. 200<577200 < 577. Not a Supercell.
  3. 198 (End): Neighbor is 109109. 198>109198 > 109. 198 is a Supercell.

Visualizing Supercells in 2D

In the grid below, Green cells represent Supercells.

243075007350987031154795912492304580863282803446
Tip

Strategy: To create many supercells, you need to alternate small and large numbers (like a checkerboard pattern of peaks and valleys).