LAWS.agrees: def of minebender-game@1.0.0.0 Import: import minebender-game@1.0.0.0/LAWS.bend as LAWS Lines 147-155 of minebender-game@1.0.0.0/LAWS.bend: https://jend.leeeet.dev/read.txt?path=minebender-game@1.0.0.0/LAWS.bend&start_line=147&end_line=155 import Base import minebender-game@1.0.0.0/types.bend as T # What the player sees at p agrees with the layout. def agrees(w: Nat, h: Nat, +layout: T.Grid(Bool), +p: T.Pos, s: T.Seen) -> Bool: match s: case T.Hidden{}: True{} case T.Shown{k}: Bool.not(mine(layout, p)) && Nat.is_eq(adj_mines(w, h, layout, p), k) case T.Boom{}: mine(layout, p) Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.not https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_eq https://jend.leeeet.dev/definition.txt?path=minebender-game@1.0.0.0/LAWS.bend&name=adj_mines https://jend.leeeet.dev/definition.txt?path=minebender-game@1.0.0.0/LAWS.bend&name=mine https://jend.leeeet.dev/definition.txt?path=minebender-game@1.0.0.0/types.bend&name=Grid https://jend.leeeet.dev/definition.txt?path=minebender-game@1.0.0.0/types.bend&name=Pos https://jend.leeeet.dev/definition.txt?path=minebender-game@1.0.0.0/types.bend&name=Seen