Set, the card game: Difference between revisions

m
Line 406:
<code>comb</code> and <code>arrange</code> are defined at [[Combinations#Quackery]].
 
<syntaxhighlight lang="Quackery"> [ true swap transpose witheach
witheach
[ 0 swap witheach +
3 mod 0if [ not conclude ] ] ] is isset ( [ --> ifb )
[ not conclude ] ] ] is isset ( [ --> b )
 
[ [ [] 81 times
[ i 4 times [ 3 /mod swap ]
[drop 3 /mod swaptimes ]join
drop
3 times join
nested join ] ] constant
shuffle swap split drop ] is cards ( n --> [ )
 
[ [] swap dup size swap 3 rot comb
dup size swap
3 rot comb
witheach
[ dip dup arrange
dup isset iff
[ nested rot join swap ]
else drop ] drop join] swap ] is sets ( [ --> [ )
else drop ]
drop ] is sets ( [ --> [ )
 
[ unpack dup dip
Line 448 ⟶ 440:
$ "squiggle"
$ "oval" ] do echo$ ]
0 > if [ say "s" ] cr ] is echocard ( [ --> )
cr ] is echocard ( [ --> )
 
[ dup cards swap
cr say "Cards dealt: " echo cr cr
dup witheach echocard cr
cr
sets dup size
say "Sets present: " echo cr cr
witheach
[ witheach echocard cr ] ] is play ( n --> )
cr ] ] is play ( n --> )
 
' [ 4 8 12 ] witheach [ play say "-----" ]</syntaxhighlight>
[ play say "-----" ]</syntaxhighlight>
 
{{out}}
1,462

edits