4 ms·
Speed is still a major issue with Raku. Parsing a log file with a regex is Perl's forte but the latest Raku still takes 6.5 times as long as Python 3.13 excludi
by cutler 2y ago
Speed is still a major issue with Raku. Parsing a log file with a regex is Perl's forte but the latest Raku still takes 6.5 times as long as Python 3.13 excluding startup time.
- donaldihunter 2y agoYou'd need to qualify that with an example. In my experience some things are faster in Raku and some are slower, so declaring that "Raku takes 6.5 times as long as Python 3.13" is pretty meaningless without seeing what it's slower at.
- cutler 2y agoI specified the use case so why "meaningless"? Here's the code: Raku for 'logs1.txt'.IO.lines -> $_ { .say if $_ ~~ /<<\w ** 15>>/; } Python from re import search with open('logs1.txt', 'r') as fh: for line in fh: if search(r'\b\w{15}\b', line): print(line, end='')