Skip to content

Instantly share code, notes, and snippets.

View Whateverable's full-sized avatar
☺️
Having fun on #raku on Libera.chat

Whateverable bots Whateverable

☺️
Having fun on #raku on Libera.chat
View GitHub Profile
@Whateverable
Whateverable / result
Created August 21, 2025 15:09
Whateverable
2025-05-28T13:51:49Z #raku-dev <ugexe> finanalyst a new method is fine too if that is was i originally recommended. a provides-docs (not doc-provides since the meta/distribution data is providing doc data). then CURI.install(...) needs to understand that provides-docs field and data and then place all the files where they need to go, rename them, precompile them, etc. in other words the heavy lifting is done in rakudo, not zef.
@Whateverable
Whateverable / query
Created August 21, 2025 07:43
evalable6
enum prio <low med high>; sub sort-jobs(@jobs) { @jobs.sort({ $^b<prio> <=> $^a<prio> || $^a<submit> <=> $^b<submit> }) }; my @jobs = do for ^20 { %(prio => prio.roll, submit => (^10).roll) }; .say for @jobs.&sort-jobs
@Whateverable
Whateverable / query
Created August 21, 2025 07:26
evalable6
enum prio <low med high>; sub sort-jobs(@jobs) { @jobs.sort({ -.<prio>, .<submit> }) }; my @jobs = do for ^20 { %(prio => prio.roll, submit => (^10).roll) }; .say for @jobs.&sort-jobs
@Whateverable
Whateverable / query
Created August 18, 2025 18:44
notable6
weekly
@Whateverable
Whateverable / query
Created August 18, 2025 02:13
evalable6
raku -e ' $_ = "ab ac ad ae af"; m:g/ (a.) { $0.say } / andthen $/.Str;
@Whateverable
Whateverable / query
Created August 18, 2025 01:07
evalable6
my $lines = (xmul(2,4)%&mul[3,7]!@^do_not_mul(5,5)+mul(32,64]then(mul(11,8)mul(8,5))); my $p1; for $lines { m:g/'mul('(\d+)','(\d+)')' {$p1 += $0*$1}/ }; say $p1;
@Whateverable
Whateverable / query
Created August 17, 2025 14:13
evalable6
g/mul( (\d+), (\d+) ) {$sum += $0 * $1}/ (basically and without the quoting)
@Whateverable
Whateverable / query
Created August 11, 2025 15:31
notable6
weekly
@Whateverable
Whateverable / result
Created August 10, 2025 11:36
Whateverable
2025-08-08T00:37:35Z #raku <SmokeMachine> librasteve_ I made a change on Red, and now you can use functions receiving 2 parameters to do the polymorphic stuff... it will use the join-model internally... I still need some ironing on the code, but here is the MR: https://github.com/FCO/Red/pull/585
@Whateverable
Whateverable / query
Created August 4, 2025 18:09
notable6
weekly