From b1693690132bced2bf266c3bf8a63eff61a9c771 Mon Sep 17 00:00:00 2001 From: Alexander Ilin Date: Fri, 1 Sep 2023 23:44:18 +0200 Subject: [PATCH] sudokus: fix compilation --- extra/sudokus/sudokus.factor | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/extra/sudokus/sudokus.factor b/extra/sudokus/sudokus.factor index a45df31f1d..ca8f0ce5d6 100644 --- a/extra/sudokus/sudokus.factor +++ b/extra/sudokus/sudokus.factor @@ -1,8 +1,8 @@ -USING: accessors arrays combinators.short-circuit grouping kernel lists -lists.lazy locals math math.functions math.parser math.ranges -models.product monads random sequences sets ui ui.gadgets.controls -ui.gadgets.layout models.combinators ui.gadgets.alerts vectors fry -ui.gadgets.labels shuffle ; +USING: accessors arrays combinators.short-circuit fry grouping +kernel lists lists.lazy locals math math.functions math.parser +models.combinators models.product monads random ranges sequences +sets shuffle ui ui.gadgets.alerts ui.gadgets.controls +ui.gadgets.labels ui.gadgets.layout vectors ; IN: sudokus : row ( index -- row ) 1 + 9 / ceiling ; @@ -14,7 +14,7 @@ IN: sudokus :: solutions ( puzzle random? -- solutions ) f puzzle random? [ indices [ f ] [ random? swap nth-or-lower ] if-empty ] [ index ] if [ :> pos - 1 9 [a,b] 80 [ pos near ] filter [ puzzle nth ] map prune diff + 1 9 [a..b] 80 [ pos near ] filter [ puzzle nth ] map members diff [ 1array puzzle pos cut-slice rest surround ] map >list [ random? solutions ] bind ] [ puzzle list-monad return ] if* ; -- 2.34.1