Programming humor thread

Home Forums Science & Tech Programming humor thread

  • This topic has 97 replies, 1 voice, and was last updated 3 weeks ago by Anonymous.
Viewing 23 reply threads
  • Author
    Posts
    • #76553
      Anonymous
      Guest

      LULZ humor thread

    • #76555
      Anonymous
      Guest

      >sharp algorithm skills
      >cannot fizzbuzz
      how does this happen?

      • #76556
        Anonymous
        Guest

        by lying on their resume.

        • #76591
          Anonymous
          Guest

          More likely not knowing what an algorithm is

      • #76628
        Anonymous
        Guest

        You have no idea the delusional type of people that the money and glamor of Silicon Valley can attract, 150 years ago they’d be dying of exposure in the Klondike convinced they know how the best way to dig gold

    • #76557
      Anonymous
      Guest

      I might have to start interviewing candidates this year and if I get someone this retarded I’m gonna fucking lose it.

    • #76558
      Anonymous
      Guest

      does anyone have the one that is a notepad++ screenshot where some guy describes all the fizzbuzz interviews he did

      • #76560
        Anonymous
        Guest

        gotcha covered

        • #76561
          Anonymous
          Guest

          that made me start to doubt that I could actually do those

        • #76562
          Anonymous
          Guest

          this made me feel like i could be a professional coder. Are coders really this bad or is it just people lying on their resumes about experience?

          • #76563
            Anonymous
            Guest

            Theres a lot of bad people out there.

          • #76564
            Anonymous
            Guest

            These people were looking for a job for a reason.

          • #76646
            Anonymous
            Guest

            colleges are businesses, they don’t make money by being exclusive or failing people

        • #76592
          Anonymous
          Guest

          >i = i%1

        • #76593
          Anonymous
          Guest

          >Find all odd numbers between 0-100
          >for(int i = 1, i >= 100, i++)
          > i >= 100
          > >=
          >8 years experience
          kek

        • #76594
          Anonymous
          Guest

          it’s also worth noting that 2 is a prime number (it is only divisible by itself and 1), so the interviewer is wrong in saying that odd numbers are 1,3,5 etc and there needs to be an extra statement stating if i == 2 print i

          • #76595
            Anonymous
            Guest

            um

            I-

            yes good point

          • #76596
            Anonymous
            Guest

            >the interviewer is wrong in saying that odd numbers are 1,3,5 etc and there needs to be an extra statement stating if i == 2 print i
            Sorry, but we don’t like know-it-alls around here, better luck next time.

          • #76601
            Anonymous
            Guest

            1 is not prime though

        • #76606
          Anonymous
          Guest

          I’m actually curious, what’s a more efficient way to make a list of all odd numbers between x and y?

          • #76607
            Anonymous
            Guest

            for a in list(range(100)):
            if a%2 == 1:
            print(a)

            or if you like, you can append ‘a’ to a list and then print the list after the loop is done

            • #76610
              Anonymous
              Guest

              >not using
              >if a&1:

              • #76621
                Anonymous
                Guest

                dont prioritize shit that your compiler is gonna do anyway over readability

                • #76644
                  Anonymous
                  Guest

                  >dont prioritize shit that your compiler is gonna do anyway over readability
                  Lol you stupid moron.

                  • #76647
                    Anonymous
                    Guest

                    You are the moron, I’m not even that guy but I can tell you that people have downright ancient ideas about what is going on in contemporary compilers.

          • #76609
            Anonymous
            Guest

            Look at the last bit of the number. If it is 1, then it is odd.

          • #76612
            Anonymous
            Guest

            butts = x || 1

            while butts < y:
            print(butts)
            # or append to list instead
            butts += 2

          • #76616
            Anonymous
            Guest

            If x is odd, start at x and increment by 2 until x is greater than y
            otherwise, start at x+1 and increment by 2 until x is greater than y

          • #76645
            Anonymous
            Guest
            • #76648
              Anonymous
              Guest

              If someone gave me this question I would be like "Can I use Haskell?" and then just type [1,3..]. Wow now I have an infinite lazily evaluated stream of odd numbers. Then if they ask for the first 100 or something you could just do ‘take 100 [1,3..]’, one line. Can’t be simpler.

        • #76608
          Anonymous
          Guest

          this cant be real

        • #76611
          Anonymous
          Guest

          Coding interviews are nothing like this.

          Either this was written in 1998, or your company is paying garbage-tier wages, or they’re bringing in high school students to interview.

          Either way, if your interview candidates are that shitty it’s totally on you.

        • #76630
          Anonymous
          Guest

          This reads like an SCP entry listing interactions

          • #76632
            Anonymous
            Guest

            These people should be contained for their own safety.

        • #76631
          Anonymous
          Guest

          I feel like you could get some of these if, every time you hit newline, you weren’t allowed to see any of the previous lines you wrote.

        • #76660
          Anonymous
          Guest

          I don’t believe this. I refuse to believe I was more employable than some actual """devs""" when I was in middle school.

          • #76661
            Anonymous
            Guest

            There’s a lot of people who focus more on looking and acting smart than actually trying to become smart.

        • #76662
          Anonymous
          Guest

          >It has logic errors too

    • #76559
      Anonymous
      Guest

      I’ve only ever used small amounts of R or python for data analysis or running motors but wouldn’t that just be something simple like (mind the pseudocode)

      for number in range(1,16):
      if number divisible by 3 and 5:
      print("FizzBuzz")
      elif number divisible by 3:
      print("Fizz")
      elif number divisible by 5:
      print("Buzz")
      else print(number)

      I don’t know what a timecode string is, I’m guessing something like 12:34:24 where it’s hours:min:seconds? Seems like an easy enough division.

      • #76642
        Anonymous
        Guest

        seconds = 0
        for n in timecode.split(‘:’):
        seconds += seconds * 60 + int(n)

        return seconds

    • #76565
      Anonymous
      Guest

      This is the result of the bootcamps and the campaigns convincing people to learn how to write code.

    • #76567
      Anonymous
      Guest

      Everybody get ready to laugh at the CSfags who think they can do better.

      • #76570
        Anonymous
        Guest

        def product(a, b):
        for i in range(b):
        a += a
        return a

        Is this right? I’m a retard who’s never coded.

        • #76572
          Anonymous
          Guest

          oh I made a retard. Replace that section with
          c += a
          return c

        • #76574
          Anonymous
          Guest

          oh I made a retard. Replace that section with
          c += a
          return c

          right but what about 1.5?

          I think the question is an esoteric computer science question – how do you teach a computer how to multiply?

          • #76575
            Anonymous
            Guest

            You made me curious so I checked and it still works.

            • #76576
              Anonymous
              Guest

              […]
              right but what about 1.5?

              I think the question is an esoteric computer science question – how do you teach a computer how to multiply?

              Ah it fails if the second variable is a float. Could fix that with a check, maybe another 3 lines?
              Still much better than

              Everybody get ready to laugh at the CSfags who think they can do better.

              • #76577
                Anonymous
                Guest

                I disagree, they are the same level.

                • #76579
                  Anonymous
                  Guest

                  The first one only works for integers up to 10. No floats at all.
                  The second one works for any integers and 1 float. That’s unarguably an improvement, but yes it needs to be fixed.

                  • #76582
                    Anonymous
                    Guest

                    Well obviously they had to stop somewhere, ten just gets the point across. Code overhead is a lot but the runtime is much faster. So there are trade offs.

                    • #76587
                      Anonymous
                      Guest

                      Wtf are you high.

              • #76580
                Anonymous
                Guest

                >Could fix that with a check, maybe another 3 lines?

                Then what do you do with the fractional part of b?

                • #76581
                  Anonymous
                  Guest

                  Remove it, I’m a chemist it doesn’t matter at our quantities when the inherent equipment uncertainties will far outweigh it :^)

            • #76578
              Anonymous
              Guest

              I set a and b to both be 1.5:
              TypeError: ‘float’ object cannot be interpreted as an integer

      • #76571
        Anonymous
        Guest
      • #76583
        Anonymous
        Guest

        I solved it, awaiting job at MIT:

        def product(a,b):
        return a/(1/b)

        • #76584
          Anonymous
          Guest

          genius

        • #76585
          Anonymous
          Guest

          That was my first thought but isn’t the challenge to avoid using any such operators?

          • #76586
            Anonymous
            Guest

            obey the letter of the law if not the spirit

        • #76605
          Anonymous
          Guest

          ah yes i see, 3*0 is indeed "ZeroDivisionError: division by zero"

      • #76598
        Anonymous
        Guest

        I solved it, awaiting job at MIT:

        def product(a,b):
        return a/(1/b)

        Use repeated doubling or a bit mask to do multi digit multiplication. Repeated doubling will be faster in general, but the bit mask has more stable run time.

        • #76615
          Anonymous
          Guest

          This holy fuck, if you are going to write ANY code at least know basic algorithms like Russian multiplication (repeated doubling). It’s the base for thousands of other similar algorithms. As long as you have a monoid you can use it.

      • #76602
        Anonymous
        Guest
        • #76604
          Anonymous
          Guest

          I didn’t realize C++ doesn’t rollover. Very nice.

    • #76568
      Anonymous
      Guest

      Imagine the kind of person that posts here in a STEM career gen thread, asking if they need to get a degree in CS or if their HS experience making a couple scripts qualifies them for 80k-250k developer jobs. Those people pumped up on confidence and dunning-kruger waltz into interviews and waste everybody’s time. It is usually either them, or boomers who just mass spam every single job listing and hope someone will hire them without checking into their skill level.

      • #76569
        Anonymous
        Guest

        Listen son, you don’t need a resume when you have a firm handshake. And if your a woman, all the same, except you grab the penis.

    • #76573
      Anonymous
      Guest

      How do I into coding?
      I’m studying chemistry but I need a backup plan because most jobs you can get with an undergrad degree pay like shit and my grades aren’t looking too hot atm.

      • #76589
        Anonymous
        Guest

        Literally just start writing shit and dicking around. Something like freecodecamp or codecadamy can give you a little structure and a nudge in the right direction.

      • #76590
        Anonymous
        Guest

        come up with a fun problem and solve it
        or
        take classes that make you suffer and put up with the suffering

        both are equally valid

      • #76603
        Anonymous
        Guest

        http://101.lv/learn/C++/htm/ch01.htm
        Think this is supposed to be a decent resource. I had to do some coding for embedded systems classes and the course coordinator recommended it.

    • #76588
      Anonymous
      Guest

      Check this one out.

    • #76599
      Anonymous
      Guest

      […]

      5 divided by 2 is : 2 and 1 halves
      3 divided by 2 is : 1 and 1 halves
      1 divided by 2 is : 0 and 1 halves

      The % is counting the halves

    • #76600
      Anonymous
      Guest

      […]

      Euclidean division, retard. 1 = 2*0 + 1.

    • #76613
      Anonymous
      Guest
      • #76634
        Anonymous
        Guest

        I don’t see the humor though. Cranking the valve open literally will ruin the entire experiment because you will get the wrong amount and over titrate it. And if you already know the amount required beforehand, then fast titrate to within 5 mL of it, then slow titrate. Literally takes less than 2 minutes to go through a 50 mL burette doing this.

        • #76640
          Anonymous
          Guest

          the humour is the absurdity of it you fucking sperg
          the second post was a pajeet pov parody post

    • #76614
      Anonymous
      Guest
    • #76617
      Anonymous
      Guest

      This fizz buzz do you have to use (n % 3 == 0 AND n % 5 == 0) print fizzbuzz elseif n % 3 == 0 print fizz elsif n % 5 == 0 print buzz else print n
      n++
      or is there a compsci way of doing it

      • #76620
        Anonymous
        Guest

        You can do n % 15 instead of n % 3 and n % 5
        Or you could parameterize it like
        Fizz : 15n, 15n + 3, 15n + 6, 15n + 9, 15n + 12
        Buzz: 15n, 15n + 5, 15n + 10
        n : 15n + 1, 15n + 2, 15n + 4, 15n + 6, 15n + 7, 15n + 8, 15n + 11, 15n + 13, 15n + 14

      • #76622
        Anonymous
        Guest

        for (i = 1, i <=100, i++) {
        if (i%15 == 0) {
        print "FizzBuzz" }
        else if (i%5 == 0) {
        print "Buzz" }
        else if (i%3 == 0) {
        print "Fizz" }
        else
        print i }

      • #76625
        Anonymous
        Guest

        in python:

        def fizzbuzz(x):
        string = ”
        if x % 3 == 0:
        string = string + ‘fizz’
        if x % 5 == 0:
        string = string + ‘buzz’
        return string

        for x in range(n):
        print(fizzbuzz(x))

        • #76627
          Anonymous
          Guest

          it has to print out the number itself in cases where the string is empty

    • #76629
      Anonymous
      Guest

      A primary school boy could do this in 20 minutes if I taught him about the basics of C. How do these people exist?

    • #76633
      Anonymous
      Guest

      >CHADdock the PUSSY slayer
      >SCIENTISTdock the BRILLIANT
      How the FUCK does he do it bros?

    • #76635
      Anonymous
      Guest

      You laugh and yet my medfag job interview included(aside from med shit) basic arithmetic/algebra tasks along the lines of
      >how would you turn 10ml of 40% solution into 200ml of 5% solution(1% in medicine means it contains 10 mg per ml)
      We are surrounded by 90iq monkeys in our daily lives, and its best not to think about it

      • #76636
        Anonymous
        Guest

        You realize you can’t turn 10 mL of 40% into 200 mL of 5%, right? Yet you claim everyone else is the 90iq monkey.

      • #76637
        Anonymous
        Guest

        1% = 10 mg/mL
        40% = 400 mg/mL
        10 mL of 40% = 4,000 mg
        Want 200 mL of 5%, which is 5 x 10 x 200 = 10,000 mg.
        Impossible to get 10k from 4k

        • #76643
          Anonymous
          Guest

          >Impossible to get 10k from 4k
          If you’re so smart why aren’t you rich?

      • #76641
        Anonymous
        Guest

        >how would you turn 10ml of 40% solution into 200ml of 5% solution(1% in medicine means it contains 10 mg per ml)
        this is actually not as dumb as it sounds. in practice you want to waste least amount of the concentrate as possible and be as accurate as possible. so no dumping the entire 10ml in water or using amounts smaller than what your equipment can accurately measure. add moles, density, equilibrium, inaccuracies, etc into account and it becomes much more than a simple arithmetic. that’s how we are taught to do it in chemistry, giving someone a lethal dose of morphine is prolly not a problem for big ego med fags

    • #76649
      Anonymous
      Guest
    • #76650
      Anonymous
      Guest
    • #76652
      Anonymous
      Guest
      • #76654
        Anonymous
        Guest

        Have the superior version

    • #76655
      Anonymous
      Guest
    • #76664
      Anonymous
      Guest

      everyone’s probably seen this by now but whatever
      "the rapidly dwindling sanity of valve programmers as expressed through code comments"

    • #76665
      Anonymous
      Guest

      I don’t actually see anything to mock here. It’s just a mismatch between the interviewer’s expectations and the applicant’s actual skillset. They freely admit that they aren’t an engineer.
      If you have a solid grasp of CSS and can handle some basic DOM manipulation with JS, then there are junior frontend dev roles out there for you.

Viewing 23 reply threads
  • You must be logged in to reply to this topic.