Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Golf tentative
- #!/usr/bin/env raku
- my %vmis_pts{Any};
- %vmis_pts = (
- '30_22-44_76' => 1,
- '31_12-47_16' => 1,
- '41_22-44_76' => 1,
- '130_22-44_77' => 1,
- '30_22-44_78' => 1,
- '30_22-44_79' => 1,
- '30_2-14_76' => 1,
- '3_22-44_36' => 1,
- '30_21-44_96' => 1,
- '80_29-42_66' => 1,
- '100_20-44_76' => 1,
- '300_21-24_71' => 1,
- '39_2-4_73' => 1,
- );
- my Str @strings = (
- 'fkdslqfj',
- 'jkfdfds',
- 'yuirefd',
- 'vcxbwn',
- 'jfdkslfdsds',
- 'fjdkslmfd',
- 'rztea yea',
- 'opfshffdad',
- 'fdsfdff',
- 'jfdsfd',
- 'qsdjkmyuozer',
- 'oeyfjglh',
- 'fswvnpmkgd',
- 'sufogkjdgsfdydf',
- );
- my $n = 0;
- for %vmis_pts.keys -> $k {
- my $match = $k.match(/^ \d+ '_' (\d+) '-' \d+ '_' (\d+) $/);
- if $match {
- %vmis_pts{@strings[$n++]} = 1;
- }
- }
- say %vmis_pts;
- Ramdomly i get this error:
- Invocant of method 'match' must be a type object of type 'Any', not an
- object instance of type 'ForeignCode'. Did you forget a 'multi'?
- in block <unit> at ./bug_memoire.raku line 37
- What is strange is randomly!!!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement