Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

agnos.is Forums

  1. Home
  2. Programmer Humor
  3. All of IT in one image

All of IT in one image

Scheduled Pinned Locked Moved Programmer Humor
programmerhumor
52 Posts 40 Posters 0 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • blackn1ght@feddit.ukB [email protected]

    This isn't the languages fault, it's the developers.

    C This user is from outside of this forum
    C This user is from outside of this forum
    [email protected]
    wrote on last edited by
    #26

    besides NaN actually being a number, this could completely and easily be avoided with typescript.

    R 1 Reply Last reply
    3
    • K [email protected]

      Yeah but no handle so you're much more likely to eat shit when you go down a slope or something.

      matty_r@programming.devM This user is from outside of this forum
      matty_r@programming.devM This user is from outside of this forum
      [email protected]
      wrote on last edited by
      #27

      Yea, it takes actual skill to use them ha ha

      1 Reply Last reply
      0
      • M [email protected]

        The Javascript literal interpretation of NaN never fails to amuse me.

        S This user is from outside of this forum
        S This user is from outside of this forum
        [email protected]
        wrote on last edited by
        #28
        "a"+"b" -> "ab"
        "a"-"b" -> NaN
        
        M 1 Reply Last reply
        1
        • E [email protected]

          Guess why he came with a truck and not on a cargo bike...

          U This user is from outside of this forum
          U This user is from outside of this forum
          [email protected]
          wrote on last edited by
          #29

          Because you forgot to tell them that you already have the dependencies at home?

          1 Reply Last reply
          2
          • V [email protected]

            I'm no acupuncturist, but I'm pretty sure that it's SUPPOSED to say "naan minutes", which is time spent enjoying delicious Indian flatbread.

            I guess you just eat your naan and then your ride arrives to ask you if you have any leftovers? 🤷

            U This user is from outside of this forum
            U This user is from outside of this forum
            [email protected]
            wrote on last edited by
            #30

            But what does that have to do with acupuncture?

            1 Reply Last reply
            1
            • F [email protected]

              NaN minutes later, a truck arrives in the alley, its license plate reads "undefined". Someone gets out of the vehicle
              "I have something for you"
              He gives you a package. You open it. It's an [object Object]

              D This user is from outside of this forum
              D This user is from outside of this forum
              [email protected]
              wrote on last edited by
              #31

              "I've been looking for you! Got something I'm supposed to deliver. Your hands only."

              1 Reply Last reply
              16
              • cm0002@lemmy.worldC [email protected]
                This post did not contain any content.
                T This user is from outside of this forum
                T This user is from outside of this forum
                [email protected]
                wrote on last edited by
                #32

                Wait until Null opens the door

                B null@slrpnk.netN 2 Replies Last reply
                11
                • C [email protected]

                  besides NaN actually being a number, this could completely and easily be avoided with typescript.

                  R This user is from outside of this forum
                  R This user is from outside of this forum
                  [email protected]
                  wrote on last edited by
                  #33

                  Naaah. Good programmers know how to use as any as any to make this work in typescript as well.

                  1 Reply Last reply
                  4
                  • T [email protected]

                    Wait until Null opens the door

                    B This user is from outside of this forum
                    B This user is from outside of this forum
                    [email protected]
                    wrote on last edited by
                    #34

                    segmentation fault

                    1 Reply Last reply
                    2
                    • S [email protected]
                      "a"+"b" -> "ab"
                      "a"-"b" -> NaN
                      
                      M This user is from outside of this forum
                      M This user is from outside of this forum
                      [email protected]
                      wrote on last edited by
                      #35

                      Yeah:

                      parseInt("a") -> NoT a NuMbEr
                      
                      S 1 Reply Last reply
                      0
                      • blackn1ght@feddit.ukB [email protected]

                        This isn't the languages fault, it's the developers.

                        scoopta@programming.devS This user is from outside of this forum
                        scoopta@programming.devS This user is from outside of this forum
                        [email protected]
                        wrote on last edited by
                        #36

                        I'm assuming by this you mean the developers of JS /s

                        1 Reply Last reply
                        0
                        • M [email protected]

                          Yeah:

                          parseInt("a") -> NoT a NuMbEr
                          
                          S This user is from outside of this forum
                          S This user is from outside of this forum
                          [email protected]
                          wrote on last edited by
                          #37

                          Sure, but the main issue here is that JS doesn't only auto cast to more generic but in both directions.

                          Maybe a better example is this:

                          "a" + 1 -> "a1"
                          "a" - 1 -> NaN
                          

                          With + it casts to the more generic string type and then executes the overloaded + as a string concatenation.

                          But with - it doesn't throw an exception (e.g. something like "Method not implemented"), but instead casts to the more specific number type, and "a" becomes a NaN, and NaN - 1 becomes NaN as well.

                          There's no situation where "a" - "b" makes any sense or could be regarded as intentional, so it should just throw an error. String minus number also only makes sense in very specific cases (specifically, the string being a number), so also here I'd expect an error.

                          If the programmer really wants to subtract one number from another and one or both of them are of type string, then the programmer should convert to number manually, e.g. using parseInt("1") - parseInt("2").

                          1 Reply Last reply
                          1
                          • blackn1ght@feddit.ukB [email protected]

                            This isn't the languages fault, it's the developers.

                            S This user is from outside of this forum
                            S This user is from outside of this forum
                            [email protected]
                            wrote on last edited by
                            #38

                            Albeit true, I want to note that some languages encourage such practices way more than others do. Also, when you've got a hammer everything looks like a string nail.

                            blackn1ght@feddit.ukB 1 Reply Last reply
                            2
                            • blackn1ght@feddit.ukB [email protected]

                              This isn't the languages fault, it's the developers.

                              C This user is from outside of this forum
                              C This user is from outside of this forum
                              [email protected]
                              wrote on last edited by
                              #39

                              It's both.

                              1 Reply Last reply
                              1
                              • B [email protected]

                                You wouldn't want your code throw an exception

                                jackbydev@programming.devJ This user is from outside of this forum
                                jackbydev@programming.devJ This user is from outside of this forum
                                [email protected]
                                wrote on last edited by
                                #40

                                [object Object]

                                1 Reply Last reply
                                1
                                • scoopta@programming.devS [email protected]

                                  As someone who mostly avoids JavaScript, I don't see the IT in this image, I just see a bad language I avoid!

                                  jackbydev@programming.devJ This user is from outside of this forum
                                  jackbydev@programming.devJ This user is from outside of this forum
                                  [email protected]
                                  wrote on last edited by
                                  #41

                                  I promise you, people make mistakes in every language lol.

                                  1 Reply Last reply
                                  2
                                  • cm0002@lemmy.worldC [email protected]
                                    This post did not contain any content.
                                    H This user is from outside of this forum
                                    H This user is from outside of this forum
                                    [email protected]
                                    wrote on last edited by
                                    #42

                                    I freaking love naan! Bring it!

                                    F 1 Reply Last reply
                                    3
                                    • H [email protected]

                                      I freaking love naan! Bring it!

                                      F This user is from outside of this forum
                                      F This user is from outside of this forum
                                      [email protected]
                                      wrote on last edited by
                                      #43

                                      NaN naan Jeremy that's insane

                                      1 Reply Last reply
                                      0
                                      • M [email protected]

                                        I got one of those too. I called the customer service to get another path home because of disturbances, and they just have robot answering. The robot started halfway through the call just reading pure json at me, and then said "to get this information as a message press 1" or something. This is what I got:

                                        Here is your journey from undefined to undefined:
                                        BUSS 506 towards Karolinska sjukhuset
                                        09:36 from undefined
                                        10:18 arrived at undefined.
                                        Link to your journey.

                                        jackbydev@programming.devJ This user is from outside of this forum
                                        jackbydev@programming.devJ This user is from outside of this forum
                                        [email protected]
                                        wrote on last edited by
                                        #44

                                        If you want those on separate lines you need to add two spaces on the end of each line!

                                        1 Reply Last reply
                                        1
                                        • dumbkid@lemmy.dbzer0.comD [email protected]

                                          What's wrong with skateboards

                                          jackbydev@programming.devJ This user is from outside of this forum
                                          jackbydev@programming.devJ This user is from outside of this forum
                                          [email protected]
                                          wrote on last edited by
                                          #45

                                          I really don't care people using skate boards, even doing it around a workplace isn't necessarily taboo in my mind, but they were in the office right outside someone's door. Do it in the parking lot or something.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups