Skip to the content

Suido水道

Turn pipes to connect the pumps and drains, through fixed levels or seeded puzzles.

Suido means water supply in Japanese. About the name

Contents

Reference · Pipes, rules and solving

SuidoChecktype

What a check says: solved, or the first reason it is not.

Import it

import type { SuidoCheck } from "@johnmorrisdotca/suido";

Definition

type SuidoCheck = {
    ok: true;
} | {
    ok: false;
    reason: string;
};

Examples

import { SUIDO_5X5 } from "@johnmorrisdotca/suido/levels-5x5";
import { levelAnswer } from "@johnmorrisdotca/suido/levels";
import type { SuidoCheck } from "@johnmorrisdotca/suido";
import { checkSuidoAnswer } from "@johnmorrisdotca/suido";

const row = SUIDO_5X5[0];
const code = row[0];
const answer = levelAnswer(row)!;
const value: SuidoCheck = checkSuidoAnswer(code,answer);
console.log(value);
{ ok: true }

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/suido 1.7.0.