Seven-sided dice from five-sided dice: Difference between revisions
Content added Content deleted
m (→{{header|Wren}}: Minor tidy) |
|||
Line 568: | Line 568: | ||
=={{header|EasyLang}}== |
=={{header|EasyLang}}== |
||
<syntaxhighlight |
<syntaxhighlight> |
||
func dice5 . |
func dice5 . |
||
return |
return randint 5 |
||
. |
. |
||
func dice25 . |
func dice25 . |
||
Line 588: | Line 588: | ||
n = 1000000 |
n = 1000000 |
||
len dist[] 7 |
len dist[] 7 |
||
# |
# |
||
proc checkdist . . |
proc checkdist . . |
||
for i to len dist[] |
for i to len dist[] |
||
Line 604: | Line 604: | ||
. |
. |
||
. |
. |
||
# |
# |
||
for i to n |
for i to n |
||
dist[dice7a] += 1 |
dist[dice7a] += 1 |
||
. |
. |
||
checkdist |
checkdist |
||
# |
# |
||
print "" |
print "" |
||
for i to n |
for i to n |