Lemmy.World
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
Gollum@feddit.de to Programmer Humor@programming.dev · 3 years ago

A fun simple game

i.imgur.com

message-square
35
link
fedilink
863

A fun simple game

i.imgur.com

Gollum@feddit.de to Programmer Humor@programming.dev · 3 years ago
message-square
35
link
fedilink
alert-triangle
You must log in or register to comment.
  • blackn1ght@feddit.uk
    link
    fedilink
    arrow-up
    153
    ·
    3 years ago

    There’s Linux distro called suicide Linux that wipes your hard drive on any mistyped command.

    • Rodeo@lemmy.ca
      link
      fedilink
      arrow-up
      35
      ·
      3 years ago

      I hope it comes preinstalled with sl and similar programs.

      • ferret@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        18
        ·
        3 years ago

        if you type sl it wipes your drive. No funny train for you

        • const@sh.itjust.works
          link
          fedilink
          arrow-up
          2
          ·
          3 years ago

          Nah; it puts funny train to make you say phew then wipes your drive anyways!

      • sip@programming.dev
        link
        fedilink
        arrow-up
        4
        ·
        3 years ago

        or with ll alias for ls -laF, I’m using it so often, even if it’s not available, I still type it 5 times a minute.

    • MonkCanatella@sh.itjust.works
      link
      fedilink
      arrow-up
      20
      ·
      3 years ago

      hardcore mode

  • theghostoutside_@aussie.zone
    link
    fedilink
    arrow-up
    84
    arrow-down
    3
    ·
    3 years ago

    Shouldn’t it be

    if guess != number
    

    Isn’t Russian Roulette played with one bullet in the chamber? Not five?

    • snooggums@kbin.social
      link
      fedilink
      arrow-up
      48
      arrow-down
      2
      ·
      3 years ago

      A chamber is the space in automatics, semiautomatic, and the slide back single shot weapons for the bullet when it is about to be fired. Any game of Russin Roulette played with a bullet in the chamber is going to be very short.

      Russian Roulette is played with one bullet in the cylinder, the spinny thing on a revolver.

      • jaybone
        link
        fedilink
        arrow-up
        5
        ·
        3 years ago

        Russian roulette hard mode: you’re hoping for a jam.

    • Johanno@feddit.de
      link
      fedilink
      arrow-up
      18
      ·
      3 years ago

      More fun like that

    • Mesa@programming.dev
      link
      fedilink
      arrow-up
      16
      ·
      3 years ago

      The game we see here is Russian Russian Roulette.

      • Zink@programming.dev
        link
        fedilink
        arrow-up
        5
        ·
        3 years ago

        Russian-in-Ukraine roulette

      • chocobo13z@pawb.social
        link
        fedilink
        arrow-up
        3
        arrow-down
        1
        ·
        3 years ago

        Polish Roulette?

    • const@sh.itjust.works
      link
      fedilink
      arrow-up
      1
      arrow-down
      2
      ·
      edit-2
      2 years ago

      It wouldn’t work anyways because decorator can’t be applied to variable setting
      Turn out I somehow mistook # as @

      Isn’t it also played with 6 slots instead of 10?

  • Synthead
    link
    fedilink
    arrow-up
    57
    ·
    3 years ago

    You’ll get an OSError if you try to remove a directory with os.remove

    https://docs.python.org/3/library/os.html#os.remove

    • KairuByte@lemmy.dbzer0.com
      link
      fedilink
      arrow-up
      29
      ·
      3 years ago

      I was gonna say, isn’t os.remove only for files? Docs say yes.

      • Zron
        link
        fedilink
        arrow-up
        6
        ·
        3 years ago

        Delete a random one of the System DLLs

        It’ll crash good and hard after a game or 2

        • yum13241@lemm.ee
          link
          fedilink
          arrow-up
          1
          ·
          3 years ago

          Just delete hal.dll.

    • CivBase
      link
      fedilink
      arrow-up
      4
      ·
      3 years ago

      shutil.rmtree('C:\\Windows\\System32')

  • glad_cat@lemmy.sdf.org
    link
    fedilink
    arrow-up
    46
    ·
    3 years ago

    No docstring, no shebang, no main function, no raw strings, and I’m sure they don’t have unit tests with a mocked filesystem.

    • enkers@sh.itjust.works
      link
      fedilink
      arrow-up
      17
      ·
      3 years ago

      Pylint is screaming right now.

      • glad_cat@lemmy.sdf.org
        link
        fedilink
        arrow-up
        3
        ·
        3 years ago

        I like https://wemake-python-styleguide.readthedocs.io/en/latest/, it’s the Nazi version.

        • MNByChoice@midwest.social
          link
          fedilink
          arrow-up
          3
          ·
          3 years ago

          it’s the Nazi version.

          I skimmed the linked doc and they don’t:

          Reformat code, since we believe that developers should do that

          Which seems more open and forgiving than some linters. What makes them strict and inflexible?

          Or did you mean actual Nazi run the project? (I hate that this is a possibility.)

          Edit: They do say they have lots of strict rules. So, I am going that is it.

          • glad_cat@lemmy.sdf.org
            link
            fedilink
            arrow-up
            3
            ·
            3 years ago

            It’s flake8 with all the rules enabled. You get a hundred warnings even for small programs. I love it.

    • darcy@sh.itjust.works
      link
      fedilink
      arrow-up
      7
      arrow-down
      1
      ·
      3 years ago

      its 14 lines

  • JackGreenEarth@lemm.ee
    link
    fedilink
    arrow-up
    22
    arrow-down
    1
    ·
    3 years ago

    Error: that file path does not exist.

    • Isoprenoid@programming.dev
      link
      fedilink
      English
      arrow-up
      19
      ·
      3 years ago

      Is that actually what happens? Let me check.

      • itsathursday
        link
        fedilink
        arrow-up
        21
        ·
        3 years ago

        String ain’t raw and \ will escape

      • JackGreenEarth@lemm.ee
        link
        fedilink
        arrow-up
        8
        ·
        3 years ago

        It’s what happens on my machine.

        • NigelFrobisher@aussie.zone
          link
          fedilink
          arrow-up
          12
          ·
          3 years ago

          It works on my machine.

          • darcy@sh.itjust.works
            link
            fedilink
            arrow-up
            9
            ·
            3 years ago

            what machine?

          • nogrub
            link
            fedilink
            arrow-up
            1
            ·
            3 years ago

            were not shipping your machine dave

  • busydoinnothin@lemm.ee
    link
    fedilink
    arrow-up
    21
    ·
    3 years ago

    I have laughed at this for too long. Good way to start the morning.

  • kSPvhmTOlwvMd7Y7E@programming.dev
    link
    fedilink
    arrow-up
    6
    arrow-down
    1
    ·
    3 years ago

    So they posted that screenshot before even trying to run it on some useless file to see it works… Internet points are surely a drug

  • dylanTheDeveloper
    link
    fedilink
    arrow-up
    1
    ·
    3 years ago

    Atleast it’s not rand float

  • MonkderZweite@feddit.ch
    link
    fedilink
    arrow-up
    2
    arrow-down
    1
    ·
    3 years ago

    deleted by creator

Programmer Humor@programming.dev

programmer_humor@programming.dev

Subscribe from Remote Instance

Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: [email protected]

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics
    • If the mod doesn’t find it funny, you’re banned. Ha-ha!.. For real: do not use the community for “statements”. There are other places for such content. Keep it chill and funny.
Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 67 users / day
  • 2.92K users / week
  • 6.88K users / month
  • 16.1K users / 6 months
  • 9.33K local subscribers
  • 33.3K subscribers
  • 2.52K Posts
  • 97K Comments
  • Modlog
  • mods:
  • Feyter@programming.dev
  • adr1an@programming.dev
  • BurningTurtle@programming.dev
  • Pierre-Yves Lapersonne@programming.dev
  • UI: 0.19.20-5-ga406e80b
  • BE: 0.19.19-9-gc55dd700c
  • Modlog
  • Legal
  • Instances
  • Docs
  • Code
  • join-lemmy.org