Skip to main content


Honestly, the Raku example (2025.49 Advent is Rolling) with the
role Sortish is written in a more complicated way than it needs to be. If someone sees that, they will definitely be put off by Raku at first I think.

There is so much going on in this role that it should be explained in a more understandable way.

In the end, you can always use the optimized syntax. I would start with next first ➡️

rakudoweekly.blog/2025/12/08/2…

This entry was edited (1 week ago)
Unknown parent

@barubary Another thing: How did you colorize your code? Your code is displayed in red in the Mastodon Web interface.
Unknown parent

mastodon - Link to source
Füsilier Breitlinger

@m3tti

Even though i think most people like if code looks more technical than actually explaining what it does.


There's definitely a balance here. Some people seem to think any "symbols" (characters other than alphanumerics and maybe ()[],) instantly make code unreadable and all identifiers should be (English) words.

I disagree. Instead of, say, "the area of the square whose side is the hypotenuse is equal to the sum of the areas of the squares on the other two sides" or "it is impossible to separate a cube into two cubes, or a fourth power into two fourth powers, or in general, any power higher than the second, into two like powers" I strongly prefer these formulations:

  • a² + b² = c²
  • ∀a,b,c,n ∈ ℕ, n > 2: aⁿ + bⁿ ≠ cⁿ

Here the "more technical" looking version also explains better to me what it's doing. But of course it is possible to go too far and get lost in a sea of obscure symbols, as well. Anyway, my point is that more technical can also mean more readable.

Sorry for the tangent.

in reply to Füsilier Breitlinger

@barubary ok thats right for calculations and everything math that makes total sense due to the fact that its a language on their own which is more narrow and compact to describe your problem space. But i was focusing on stuff like managing users and doing iterations and stuff like that. "Business Logic" as people might call it.

But i totaly get your point my point was just for stuff that describes the flow of the programm.

Unknown parent

mastodon - Link to source
Füsilier Breitlinger
glitch-soc supports fenced code blocks, but without the syntax highlighting (it's just plain ```...```):
{<br>  "lastName": "Smith",<br>  "firstName": "John",<br>  "age": 25<br>}<br>
in reply to (roll m3tti)

@m3tti

"Business Logic" as people might call it.


Heh. We might describe it using some sort of Common Business-Oriented Language and make it very readable and English-like. 😈

in reply to Füsilier Breitlinger

@barubary
mhhh

Somehow it doesn't work for me.
norden.social/@leobm/115688763…

in reply to Füsilier Breitlinger

It would be fun if someone wrote a Greasemonkey or browser extension that correctly displays (extended) Markdown in the browser within #Mastodon. Or has someone already done that?
This entry was edited (1 week ago)
Unknown parent

mastodon - Link to source
Paul Evans
@enigma That was a lesson we learned for Perl signatures. Each parameter default is an expression that is evaluated when it is needed at calltime. The equivalent example in #perl would get a fresh arrayref every time.
Unknown parent

mastodon - Link to source
Füsilier Breitlinger
@enigma @leonerd I don't think Larry Wall has actively worked on perl (5) since 2000.
Unknown parent

mastodon - Link to source
Füsilier Breitlinger
@enigma @leonerd Not sure what you mean by "it", but the feature under discussion (default values for function parameters) was added in perl 5.20, which came out in 2014. So for better or worse, you can't blame this one on Larry.