User:Underscore/Scratchpad: Difference between revisions
Content added Content deleted
Underscore (talk | contribs) |
Underscore (talk | contribs) |
||
Line 12: | Line 12: | ||
<li> <code>&multiply = [*];</code></li> |
<li> <code>&multiply = [*];</code></li> |
||
<li> <code>&multiply = &infix<*>;</code></li></ul></li> |
<li> <code>&multiply = &infix<*>;</code></li></ul></li> |
||
<li> [[Greatest common divisor#Perl 6|Greatest common divisor]]: <code>($a, $b, &[%] ... 0)[*-2]</code> |
|||
<li> [[Happy Number#Perl 6|Happy Number]]: Laziness. |
|||
<li> [[Monty Hall simulation#Perl 6|Monty Hall simulation]]:<ul> |
<li> [[Monty Hall simulation#Perl 6|Monty Hall simulation]]:<ul> |
||
<li> <code>:delete</code> adverb.</li> |
<li> <code>:delete</code> adverb.</li> |
||
<li> More trials.</li></ul></li> |
<li> More trials.</li></ul></li> |
||
<li> [[Playing Cards#Perl 6|Playing Cards]]: There really ought to be something like <code>EnumerationType.pick(*)</code> that gives you the values of the enumeration ''in order''. You'd think <code>Two .. Ace</code> would do it, but as of Rakudo release #22, that produces numbers, not Pips. |
|||
<li> [[Trigonometric Functions#Perl 6|Trigonometric Functions]]: The base-switching interface specified in <code>Numeric.pod</code>. |
<li> [[Trigonometric Functions#Perl 6|Trigonometric Functions]]: The base-switching interface specified in <code>Numeric.pod</code>. |
||
<li> [[True/False Values#Perl 6|True/False Values]]: <code>0 but True</code>. </li> |
|||
</ul> |
</ul> |