mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-05-19 04:40:59 +00:00
Fixed instance where wrong variable name was used
This commit is contained in:
parent
684bae87ef
commit
74ea20793d
@ -824,7 +824,7 @@ say why-not[^5]; #=> 5 15 25 35 45
|
|||||||
# (they exist in other langages such as C as `static`)
|
# (they exist in other langages such as C as `static`)
|
||||||
sub fixed-rand {
|
sub fixed-rand {
|
||||||
state $val = rand;
|
state $val = rand;
|
||||||
say $rand;
|
say $val;
|
||||||
}
|
}
|
||||||
fixed-rand for ^10; # will print the same number 10 times
|
fixed-rand for ^10; # will print the same number 10 times
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user