This channel is intended for people just starting with the Raku Programming Language (raku.org). Logs are available at irclogs.raku.org/raku-beginner/live.html
Set by lizmat on 8 June 2022.
02:20 teatwo joined 02:21 teatwo left 02:22 teatwo joined 02:24 tea3po left 02:40 teatwo left 02:41 teatwo joined 08:26 rantanplan left 08:29 snonux joined 08:48 habere-et-disper joined
habere-et-disper Pray tell, is there a raku equivalent of the perl : 08:53
not exp log srand xor s qq qx xor
s x x length uc ord and print chr
ord for qw q join use sub tied qx
xor eval xor print qq q q xor int
eval lc q m cos and print chr ord
for qw y abs ne open tied hex exp
ref y m xor scalar srand print qq
q q xor int eval lc qq y sqrt cos
and print chr ord for qw x printf
each return local x y or print qq
s s and eval q s undef or oct xor
time xor ref print chr int ord lc
foreach qw y hex alarm chdir kill
exec return y s gt sin sort split
www.perlmonks.org/?node_id=290607
librasteve no, but I sense that you are the person to write it! 09:03
Nemokosch is this just a list of keywords? 😅 09:04
habere-et-disper Of course, it might have to read somewhat modified, perhaps : 09:08
"Just another raku raccoon"
The longest (so far) I've accidentally written reads in part : 09:57
"... and so all gather for map ..."
😀
10:24 frost88 joined 11:03 frost88 left 11:06 habere-et-disper left 12:54 habere-et-disper joined 13:49 tea3po joined 13:52 teatwo left 14:20 teatwo joined 14:23 tea3po left 14:41 ab5tract joined 15:24 habere-et-disper left 17:08 ab5tract left 18:42 gfldex joined 19:16 Poohmaan joined
Poohmaan Hello all 19:16
(1..10).map(->$a {$a+1}) 19:17
Can I do something like the above with the reduce function as well?? 19:18
(1..10).reduce(->$a (&fun, $accumulator)) 19:20
I'm looking for something like the above
(1..10).reduce(->$a (&fun($a,$accumulator))) 19:21
(array of hashes). reduce(->%a (&fun, %a, $accumulator)) 19:24
Where the fun has the signature fun(%a, $accumulator) 19:25
19:37 Poohmaan left, Poohmaan joined 19:47 Poohmaan left
Nemokosch Hello. Good question, I don't think so actually. The "accumulator" is really just the first/last element, depending on precedence 20:30