Non-transitive dice: Difference between revisions
Content added Content deleted
(J) |
m (→{{header|J}}) |
||
Line 361: | Line 361: | ||
=={{header|J}}== |
=={{header|J}}== |
||
Implementation (here, we consider X<Y<Z and Y<Z<X to be the same sequence of dice) |
|||
Implementation: |
|||
<lang J>NB. unique list of all y faced dice |
<lang J>NB. unique list of all y faced dice |
||
udice=: {{ 1+~./:~"1 (#: ,@i.)y#y }} |
udice=: {{ 1+~./:~"1 (#: ,@i.)y#y }} |