Alt Text

Bluesky post by user @magnusbeefcastle.bsky.social that reads,

I INSTALLED “LINUX”. BECAUSE WINDOWS IS FOR MEN WHO ASK PERMISSION TO EXIST. I CRUSHED THE INSTALLER WITH MY BARE HANDS AND NOW THE TERMINAL CALLS ME “SIR” BUT MY KERNEL KEEPS PANICKING. WHAT COMMAND MAKES THE COMPUTER SUBMIT COMPLETELY? I REFUSE TO GOOGLE

Link to original post

~Yes, all of this user’s posts are like this.~

  • rbos@lemmy.ca
    link
    fedilink
    English
    arrow-up
    13
    ·
    25 天前

    If you replace : with “loop” it becomes pretty clear. The only ‘weird’ thing is using punctuation as a function name.

    • lime!@feddit.nu
      link
      fedilink
      English
      arrow-up
      14
      ·
      edit-2
      25 天前

      it’s not just looping; every instance starts two instances of itself waiting for input. it’s basically doing

      async def fork(): 
          f = fork()
          await fork(await f)
      

      …except python doesn’t start the second call until its arguments are evaluated, while shell does.

      • rbos@lemmy.ca
        link
        fedilink
        English
        arrow-up
        4
        ·
        25 天前

        Yeah, “loop” was a poor choice of keywords. My point was that replacing : with a more plain identifier helps it make sense. :)

    • Wirlocke@lemmy.blahaj.zone
      link
      fedilink
      English
      arrow-up
      3
      ·
      25 天前

      I think it’s meant to be confusing. If you’re unfamiliar with code, you’ll likely glaze over the random string of symbols and assume it’s like broken HTML or JSON or something.

      Hell even if you are a programmer, I think most programmers assume you can’t use a colon in a variable or function name, much less just a colon.

      • rbos@lemmy.ca
        link
        fedilink
        English
        arrow-up
        5
        ·
        edit-2
        25 天前

        Definitely. But it’s worth expending some skull meat to understand what’s going on. :)

        In some of my university classes I liked to use Hiragana characters (from Japanese) for variables and function names, just to be a jerk.

      • lime!@feddit.nu
        link
        fedilink
        English
        arrow-up
        3
        ·
        24 天前

        learning that the shell [[ is a function and ]] is an argument definitely did something to my brain.