Reference · Rules, generation and deductions
Constrainttype
An exact count over unknown cells, with the clues that supplied it.
Import it
import type { Constraint } from "@johnmorrisdotca/jirai";
Definition
type Constraint = {
cells: readonly number[];
mines: number;
sources: readonly number[];
};
Members
| Name | Type | Description |
|---|---|---|
cells | readonly number[] | |
mines | number | |
sources | readonly number[] |
Examples
import type { Constraint } from "@johnmorrisdotca/jirai";
const value: Constraint = {cells:[0,1],mines:1,sources:[2]};
console.log(value);{ cells: [ 0, 1 ], mines: 1, sources: [ 2 ] }What it prints (run when this page was built)