Functional programming languages are overrated. Imperative languages are more intuitive and practical.

Functional programming languages are overrated. Imperative languages are more intuitive and practical.

Man-made Horrors Shirt $21.68

POSIWID: The Purpose Of A System Is What It Does Shirt $21.68

Man-made Horrors Shirt $21.68

  1. 1 week ago
    Anonymous

    more intuitive to morons, yes

    • 1 week ago
      Anonymous

      /thread

    • 6 days ago
      Anonymous

      Fippy bip

  2. 1 week ago
    Anonymous

    We have graduated from "lust-provoking image, irrelevant time-wasting question" to "lust-provoking image, simple statement of fact"

    • 1 week ago
      Anonymous

      It's more like "lust-provoking image, irrelevant moronic opinion"

      • 7 days ago
        Anonymous

        more intuitive to morons, yes

        /thread

        The functional programmers cry out in pain because they know they will never be paid to write unmaintainable garbage in their memelang of choice

  3. 1 week ago
    Anonymous

    >takes best parts of functional and imperative languages
    Nothing personnel, kiddo

    • 1 week ago
      Anonymous

      "best" is a subjective term.
      veeeeeery subjective

      • 1 week ago
        Anonymous

        >Jobs
        lmao, get back to work waggie.

      • 5 days ago
        Anonymous

        literally the most pathetic spammer on this board. Wouldn't surprise me if the same homosexual doing this is the same homosexual doing the BG3 Tencent spam.

    • 1 week ago
      Anonymous

      > ESL
      LMAO

      • 6 days ago
        Anonymous

        lurk moar, you reddit tourist

    • 1 week ago
      Anonymous

      Pure functional programming languages give you a GUARANTEE of no side effects.

      and pairs them with Java tier garbage syntax instead of superior Haskell like syntax.

      • 1 week ago
        Anonymous

        Rust syntax has practically nothing in common with Java.
        And syntax itself does not matter anywhere nearly as much as semantics and paradigms.

      • 1 week ago
        Anonymous

        >a GUARANTEE of no side effects
        this is what morons don't get. My biggest issue with Elixir is that it didn't bring on some of the most important functional features to keep it "practical" for morons

        • 1 week ago
          Anonymous

          Elixir is a waste of time, Erlang works just fine.

          • 1 week ago
            Anonymous

            nah its 100% an improvement to erlang, that's not even a question
            but it could have been even a bigger improvement, just needed proper types and monads built in

          • 1 week ago
            Anonymous

            There is no improvement. Elixir is an additional (unnecessary) overhead that just makes developing more complicated by introducing new syntax and changing established erlang development practice, only for the end product to be translated into erlang code. At the same time elixir does nothing that erlang/otp cannot do (because it is erlang just with additional garbage on top)

          • 1 week ago
            Anonymous

            >end product to be translated into erlang code
            so you don't know what elixir is?
            >At the same time elixir does nothing that erlang/otp cannot do
            Scala can't do anything java can't either moron, that's not the point

        • 1 week ago
          Anonymous

          we also did distinguish between functional and pure functional. erlang/otp was never pure.

  4. 1 week ago
    Anonymous

    how many inches does this fine specimen have?

    • 1 week ago
      Anonymous

      3 when hard

  5. 1 week ago
    Anonymous

    boomer plz. no one uses either.
    imperative languages went out of mainstream in the 1990s.
    functional ones never were mainstream.

    • 1 week ago
      Anonymous

      zoomer pls, what exactly do you think modern mainstream languages are

      • 1 week ago
        Anonymous

        all modern mainstream languages are multi-paradigm

  6. 1 week ago
    Anonymous

    >Functional programming languages are overrated. Imperative languages are more intuitive and practical.

    • 1 week ago
      Anonymous

      they are tho
      when you ask people who do functional why did they learn it its always
      "i think it looks neat"

      • 1 week ago
        Anonymous

        lies.
        explain how you would do something like pic in an imperative language. it's neither intuitive nor practical.

        • 1 week ago
          Anonymous

          >webshit
          >webshit take
          pottery

          nobody should write react full stop.
          whether its possible to build wo functional is redundant

          functional programming is back showing faith in the compiler. Faith that the compiler will inline the ever living frick out of your code while compiling so that performance can reach a farts-breath of the performance of the imperative fashion

          compilers are kinda dum, to bh. id rather control what gets force-inlined manually, thank you

          • 1 week ago
            Anonymous

            no one has ever done any gui in imperative style. it's moronic.

          • 1 week ago
            Anonymous

            >wenshit
            >webshit take
            yeah, nobody, except everyone until ~mid 90's
            and a good portion of people until mid 2000's

            you webshitters are utterly fricking obnoxious
            and illiterate. thats what makes you obnoxious to begin with

            >Jobs
            lmao, get back to work waggie.

            so youre saying...
            ...rust is for the unemployed? kek

          • 1 week ago
            Anonymous

            >yeah, nobody, except everyone until ~mid 90's
            >and a good portion of people until mid 2000's
            i don't think you know what imperative means then.
            just because you could abuse an imperative language to write some OOP doesn't make it imperative.

          • 1 week ago
            Anonymous

            >just because you could abuse an imperative language to write some OOP doesn't make it imperative.
            >use wraping your data and functions into structures makec C an OOP language
            thats the webshittest thing ive read today

            congratulations, anon. thats quite the achievement considering ive been here for 4 hours already and i had the time to speak with some of the visiting lgbtrash

          • 1 week ago
            Anonymous

            so you really have no idea and go just by programming language.
            the C in Motif, GTK, Windows, ... is OOP.
            even a nocoder like you could read this on wikipedia.
            https://en.wikipedia.org/wiki/Windows_API#Program_interaction
            >Despite the fact that C is not an object-oriented programming (OOP) language, the Windows API is somewhat object-oriented due to its use of handles.

          • 1 week ago
            Anonymous

            bruh
            if i do C its bc i dont give half a shit if its oop or otherwise
            its all fricking pointers and jump tables, regardless of the language

          • 1 week ago
            Anonymous

            >its all fricking pointers and jump tables, regardless of the language
            this doesn't sound very imperative.
            shouldn't you use a language paradigm that has recursion front and center?

          • 1 week ago
            Anonymous

            >paradigm that has recursion front and center?
            WHY?
            recursion is terrible
            youre keeping all the contexts of your containing functions in your cache

            no
            i dont follow a pradigm
            i just make computers go brr (in a broken voice)

          • 1 week ago
            Anonymous

            >recursion is terrible
            Not in functional.

          • 1 week ago
            Anonymous

            actual recursion is always terrible.
            that your compiler/interpreter turns you function into a simulated recursion is a whole other thinig
            bc yes
            you can re-write a recursive algo into non-recursive code

          • 1 week ago
            Anonymous

            >actual recursion is always terrible.
            Not in functional.
            You don't need context if your functions are pure and deterministic. Tail-end recursive functions in Haskell will compile to the same assembly as a for-loop in C.

            You should try it anon, you might like it.

          • 1 week ago
            Anonymous

            >actual recursion is always terrible.
            it is always bad regardless of the language bc physics anon
            >Tail-end recursive functions in Haskell will compile to the same assembly as a for-loop in C.
            thats exactly what i was saying
            your code gets re-written into its non-recursive form bc recursion is extremely bad and jesus cries everytime you use *effective recursion and you should feel bad for even considering recursion in the first place because its the root of all evil, satan, and a corruptor of the youth

          • 1 week ago
            Anonymous

            >it is always bad regardless of the language
            I gave you a clear explanation as to why it isn't.
            >your code gets re-written into its non-recursive form
            Assembly doesn't have for-loops either.

          • 1 week ago
            Anonymous

            >I gave you a clear explanation as to why it isn't.
            im talking about *effective recursion
            how the code looks in assembly
            as in: a function that calls itself
            not what you write in the code.
            ->what it compiles to

            >>your code gets re-written into its non-recursive form
            >Assembly doesn't have for-loops either.
            but it does have recursion mr diversion

          • 1 week ago
            Anonymous

            >*effective recursion
            This doesn't exist and doesn't make sense.
            There's no reason why your code should look like its assembly counterpart. Do you avoid variables and GOTO everywhere on your code?

          • 1 week ago
            Anonymous

            >There's no reason why your code should look like its assembly counterpart.
            why?
            bc you definitely cant expect something of the sort with functional?

            >Do you avoid variables and GOTO everywhere on your code?
            you can also inline your functions and let the compiler sort it out 😉

          • 1 week ago
            Anonymous

            >you can also inline your functions and let the compiler sort it out 😉
            what?
            if your functions are already inlined, what's the compiler supposed to do?

          • 1 week ago
            Anonymous

            avoid redundant operations.
            like avoid copying data to eax (iirc).
            but also all the -O3 tier shenanigans im not thinking about
            programming is a group effort.
            you gotta be a team player. even if youre the on on front and center

          • 1 week ago
            Anonymous

            >avoid redundant operations.
            are you saying some compiler will extract inlined functions? never heard of this. even -Os in gcc still does -finline-functions.

          • 1 week ago
            Anonymous

            >bc you definitely cant expect something of the sort with functional?
            Because your high level code should work independently of how the CPU works.
            Also, you can't expect it from any paradigm. Assembly relies on Jumping/Branching, which old languages despised and new languages don't even implement. You'd also need to manually load and write every variable into memory using a limited amount of registers - which would be impossible, since you don't necessarily know the architecture your code will run under.
            Your argument is no-coder cope, you clearly have no clue what you're talking about but is too emotionally invested to admit you're wrong.

          • 1 week ago
            Anonymous

            im not wrong doe
            >Because your high level code should work independently of how the CPU works.
            and because of that 80% of the libc is deactivated by ifdefs every time you compile C.

            you know shit and only form hearing.
            stop taking ritalin, homosexual

          • 1 week ago
            Anonymous

            >and because of that 80% of the libc is deactivated by ifdefs every time you compile C.
            This has nothing to do with the point I made.
            >you know shit and only form hearing.
            You're just spouting random shit. I imagine you're just here to derail, but I honestly don't mind. At least the one thread about functional goes to the front page.

          • 1 week ago
            Anonymous

            >This has nothing to do with the point I made.
            no, its just that your autismo ass doesnt follow. bc yo ure high on prescription cocaine aka ritalin
            it is relevant bc it shows that the """"""""portability"""""""" of c is achieved with duplicate code.
            absolute tons of it

            >avoid redundant operations.
            are you saying some compiler will extract inlined functions? never heard of this. even -Os in gcc still does -finline-functions.

            >are you saying some compiler will extract inlined functions?
            its should. its trivial. if i could do it, you can be sure people exponentially smarter than me did

            >-Os in gcc still does -finline-functions.
            >2 completely contradictory flags
            are you unwell?
            like have you experienced head trauma in recent times?
            also wtf does it have to do with the rest of the conversation?

          • 1 week ago
            Anonymous

            >it is relevant bc it shows that the """"""""portability"""""""" of c is achieved with duplicate code.
            Even if it were, it has nothing to do with the conversation.

          • 1 week ago
            Anonymous

            >nuh uh bc i sed so
            autism is a hard moronation, theres no two ways about it

          • 1 week ago
            Anonymous

            >>2 completely contradictory flags
            talk to gcc devs then -- the ones you just called exponentially smarter than yourself:
            https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-Os

          • 1 week ago
            Anonymous

            lmao
            >tunes for size instead of speed
            and? even if that wasnt the cae, what did you even mean by that?
            >nuh it inlines but its explicitly told to inloine but its actually doent, but in the manual it says it does
            heres the fix:
            attribute((__always_inline__))

            why would you even use the fricking flags to begin with?
            if you remove the L of "flags" it spells "gays"
            its like an irrational number

          • 1 week ago
            Anonymous

            for size instead of speed
            in what other case would you want to extract inlined functions?

          • 1 week ago
            Anonymous

            again
            like the autists you are
            youre thinking wrong
            completely asswise

            ->why woudNT you extract inlined functions?

          • 1 week ago
            Anonymous

            you are inlining functions because function calls are slow

          • 1 week ago
            Anonymous

            youre avoiding the question. again.
            and youre very bad at that

            why wouldNT you extract an inlined function?

          • 1 week ago
            Anonymous

            which part of my answer wasn't clear?

          • 1 week ago
            Anonymous

            your answer is very clear.
            its just that its a very immature way of saying you dont know.

            there is no reason not to extract an inlined function bc its a case of:
            {a = b; b = c}
            =>a = c

            you need to learn to be less of a homosexual
            and to understand theres tons of shit you dont know
            we all have limits to our respective knowledge. its a fact of life.

          • 1 week ago
            Anonymous

            >there is no reason not to extract an inlined function bc its a case of:
            >{a = b; b = c}
            >=>a = c
            it's not.
            read up what inlining functions actually does.

          • 1 week ago
            Anonymous

            reading books is for homosexuals
            you can just look at what the asm does
            >inb4 when you have 500 variables
            *wet fart noises*
            i dont really care
            its the edgiest of edge cases

          • 1 week ago
            Anonymous

            >you should feel bad for even considering recursion in the first place because its the root of all evil, satan, and a corruptor of the youth
            It's easier to mathematically verify that recursive code is correct through induction proofs. Everyone else uses placebos like tests.

          • 7 days ago
            Anonymous

            >just become a trained mathematician to write the same code in a more complicated way

          • 7 days ago
            Anonymous

            But functional code is less complicated

          • 7 days ago
            Anonymous

            then how come you can write every recursive function with a (for i = 0; i > x; i++) with less lines. faster performance and with less cognitive wok being required to understand it

          • 7 days ago
            Anonymous

            That immediatly changes when loop gets more complicated (and more bloated) while recursion stays more or less the same

          • 7 days ago
            Anonymous

            >with less lines
            Not really, most recursion is 2-3 lines long in Haskell. And that's if you even bother to write them, most can be expressed as maps, folds, and the like.
            >faster performance
            Not true, performance loss only happens if you need to context switch.
            >less cognitive wok
            I don't think this is true at all, reasoning with recursion is very intuitive. A lot more than array positions, at least.

          • 7 days ago
            Anonymous

            >inb4 only written fizbuzz loops

          • 7 days ago
            Anonymous

            This moronic post aside, it's kind of funny how people have a lot of trouble understanding set builder notation but find it easy to understand for loop notation when they're almost the same thing.

          • 7 days ago
            Anonymous

            Only if you wanna delve deep into the concept of the language. You don't need to know what a monad is to use Haskell, just like most bootcamp webdevs don't know what a pointer is and still data structures.

          • 7 days ago
            Anonymous

            It's less complicated and I am a trained mathematician. That's not the point though, the point is that software verification is hard, but it becomes easier with recursion.
            It's terrible that most big companies just rely on test driven development (which doesn't actually verify correctness but instead attempts to do a basic sanity test) for all of their critical code. It should chill you to the bone to hear that the autopilot computers on Boeing planes have to be rebooted once every so many days otherwise they may spontaneously crash mid-flight causing the pilot to temporarily lose control of the plane while the system reboots. Verifying that software is correct is absolutely something you should be demanding and wanting to do.

          • 7 days ago
            Anonymous

            >It should chill you to the bone to hear that the autopilot computers on Boeing planes have to be rebooted once every so many days otherwise they may spontaneously crash mid-flight
            this is literally a heap fragmentation error. literally fricking xbox and sony have higher standards for developers making games for their hardware. if your console game crashes after running for a week straight it doesn't ship.
            all this tells me is that game developers are more competently trained than people charged with the safety of hundreds of lives

          • 7 days ago
            Anonymous

            >if your console game crashes after running for a week straight it doesn't ship.
            How does that work? My console cyberpunk 2077 crashed after about 2 hours gameplay so I guess that's fine but if a game runs straight for a week without any problems and then crashes, well that's a problem and it cannot be shipped. Seems like a shitty standard tbh

          • 7 days ago
            Anonymous

            remember when sony pulled the game off the psn store at launch and offered full refunds?

          • 1 week ago
            Anonymous

            >GUI
            >webshit
            Spoken like a true nocoder. Anon is right. I like functional programming because it's quirky. I still like imperative programming for most projects but for GUI, functional is a must.

          • 1 week ago
            Anonymous

            >webshit tier reading comprehension
            i didnt say "webshit" bc "gui"
            i said "webshit" bc "fricking moronic take"

            and i was pretty clear about that
            >>just because you could abuse an imperative language to write some OOP doesn't make it imperative.
            >>use wraping your data and functions into structures makec C an OOP language

          • 5 days ago
            Anonymous

            I mean, Dear ImGui and other immediate mode guis actually exist and get used.

          • 1 week ago
            Anonymous

            >compilers are kinda dum, to bh. id rather control what gets force-inlined manually, thank you
            No, modern compilers are incredibly smart and it's basically impossible for a human to perform better on average.
            At most humans can use trial-and-error to improve small parts by testing with real world data - a process that could also be automated.

          • 1 week ago
            Anonymous

            >No, modern compilers are incredibly smart
            what are modern compilers?
            Fortran compilers from decades ago could auto-vectorize, something modern C compilers can't do.
            >it's basically impossible for a human to perform better on average.
            wrong.
            why do you think there are intrinsics in C?

        • 1 week ago
          Anonymous

          You're correct. React is neither intuitive nor practical.

          • 1 week ago
            Anonymous

            >the most popular front end framework, mastered by even 50IQ jeets, is neither intuitive nor pratical
            lol

      • 1 week ago
        Anonymous

        functional programming is back showing faith in the compiler. Faith that the compiler will inline the ever living frick out of your code while compiling so that performance can reach a farts-breath of the performance of the imperative fashion

        • 1 week ago
          Anonymous

          >inline lazily evaluated unbounded iterators
          keep dreaming

          • 1 week ago
            Anonymous

            >FP
            >iterators
            choose one

          • 1 week ago
            Anonymous

            Functional programming is the only way to construct large, complex and correct programs.

            Functional iterators. AKA Streams.

          • 1 week ago
            Anonymous

            Unironically True

          • 1 week ago
            Anonymous

            Unironically True

            Wrong.

      • 6 days ago
        Anonymous

        >when you ask people who do functional why did they learn it its always
        >"i think it looks neat"
        Who the hell have you been talking to? The main draws towards functional programming that everyone talks about are data immutability, predictability, safety, etc. I have never once heard "it looks cool."

        • 6 days ago
          Anonymous

          I love erlangs processes and concurrency (safety and data immutability has a lot to do with it) also the code legitimately looks more straightforward and easier to read, not saying it can't be made into a convoluted mess but it's just easier to develop following simple conventions than go out of your way to convolute it.

          • 6 days ago
            Anonymous

            women are stupid, and i don't respect them

          • 6 days ago
            Anonymous

            I fully agree with you, brother.

  7. 1 week ago
    Anonymous

    Eval. Apply.

  8. 1 week ago
    Anonymous

    What's the use-case of wearing a skirt and long sock combination that still leaves part of your leg exposed instead of just wearing pants?

    • 1 week ago
      Anonymous

      sexo

    • 1 week ago
      Anonymous

      It's breezier and more comfortable :3

      • 1 week ago
        Anonymous

        The girl in that picture? Actually a man

        • 1 week ago
          Mr Jamieson

          >The girl in that picture? Actually a man

          Listen here homosexual! I'm straight therefore whatever I stick my dick into is a woman.

        • 1 week ago
          Anonymous

          and look at how breezy and comfortable he is.

    • 7 days ago
      Anonymous

      The socks protect the most vulnerable parts of the legs while still allowing the wearer the comfort and mobility of a skirt.

      • 7 days ago
        Anonymous

        Bring Back Pantaloons

    • 7 days ago
      Anonymous

      airs out the fufu

    • 6 days ago
      Anonymous

      looks nice

    • 5 days ago
      Anonymous

      Draws the eye to the exposed skin, which is close to the rear, thereby eliciting a low grade sexual response to favorably influence and reduce gender dysphoria

  9. 1 week ago
    Anonymous

    >Imperative languages are more intuitive
    They actually aren't. The first 6 months of any computer-oriented course, be it bootcamps or uni degrees, is trying to explain imperative concepts to people.

    • 1 week ago
      Anonymous

      They don't even teach functional languages at courses because they're useless.

      • 1 week ago
        Anonymous

        If they weren't, Haskell wouldn't be the most influential language of the last decades
        >"functional methods", also known as intuitive way of doing operations, were added to every language
        >lambdas became so popular even a python dev knows what they are
        >everyone's favorite villain, Rust, is strongly influenced by functional
        >currying is becoming more popular, having already been adopted by JavaScript
        >Elm, which is very strongly inspired by Haskell, inspired the most popular frontend frameworks such as React and Vue

        Most courses don't teach functional because teachers are lazy fricks who just wanna teach the same thing forever. Back in my uni days the professors didn't even wanna teach Python or JavaScript, let alone Haskell.

        • 5 days ago
          Anonymous

          is becoming more popular,
          Yes, Indians have infested all aspects of IT.

          • 5 days ago
            Anonymous

            gm sir
            That is NOT what I meant!!

      • 6 days ago
        Anonymous

        Every major imperative language is post-facto bolting on functional features because they saw how insanely easy it made designing actual working software in newer functional and functional-leaning languages. You're coping. If you want to build systems that work and build them quickly, functional languages are used across the industry to employ fewer engineers, at higher quality, and with better results. And you don't even need the whole functional featureset, referential transparency and expression-based programming get you 80+% of the benefit.

        • 6 days ago
          Anonymous

          Every day, imperative languages implement more and more functional methods.
          Meanwhile, Haskell is still purely functional.

          One day, all these imperative programmers will be writing Haskell and they won't even realize it.

    • 1 week ago
      Anonymous

      bait

      • 7 days ago
        Anonymous

        Not bait at all. I just keep in touch with beginners so I've noticed what they struggle with.
        A lot of beginners, for example, struggle with the concept of for-loops. These courses will sometimes spend weeks on this concept that we both would consider trivial.
        When confronted with a container (like a list, array, etc.), most people will reason something like "I want to do X on each element". Translating it into [C-like] for-loops will read like "For each number between 0 and the length of the container minus one, do X" which is absolutely not intuitive. Sure, after you "get it" you get it, but it's not intuitive.
        The functional solution, map/fmap, just makes sense. It really reads as "do X on whatever is inside the container" and that's that.

        • 7 days ago
          Anonymous

          >A lot of beginners, for example, struggle with the concept of for-loops. These courses will sometimes spend weeks on this concept that we both would consider trivial.
          People, barring Black folk, are not that stupid. If they struggle with it it's because it is badly explained. I don't think anyone have trouble understanding for loops, or maybe the syntax for 5 mins, but how do you use for-loops is whole other matter. I bet you that all the time is spent going from meaningless exmaple to meaninless example without an end and that will confuse the shit out of begginers. On top of that, the longer the course stay on that subject, the more the students will think that there is something deep about for-loops that they don't understand.
          I'm assuming for-loops in an automatically memory managed langauge though. Of course if you teach anyone control flow and programming patterns + pointers + memory management in C with zero previous knowledge they won't get it.

          >The functional solution, map/fmap, just makes sense. It really reads as "do X on whatever is inside the container" and that's that.
          You're right, it's probably simpler. I thought you meant pure FP with recursion for everything or some shit.
          On second though, I think the best thing to do is teach beginers imperative iterations and equivalent map/filter functions at the same time, on a GC language that his both imperative and "functional", and let them choose whatever they want.

          • 7 days ago
            Anonymous

            >People, barring Black folk, are not that stupid.
            It's not a matter of stupidity, it's just a new concept that must be internalized. You'll see a lot of beginners struggle with it, even extremely bright STEM students who are taking a course in programming "just because".
            >I bet you that all the time is spent going from meaningless exmaple to meaninless example without an end and that will confuse the shit out of begginers.
            This is essential for learning though. The first phase of learning anything is just copying what others are doing, and this stands for every type of knowledge.
            > the longer the course stay on that subject, the more the students will think that there is something deep about for-loops that they don't understand.
            This is true.

  10. 1 week ago
    Anonymous

    I'm never going to use Rust.
    I'm never going to use Haskell.
    I'm never going to use Go.
    I'm never going to use Python.

    You can shut up now.

  11. 1 week ago
    Anonymous

    i would do it forcefully if necessary.

  12. 1 week ago
    Anonymous

    >his language doesn't allow functional and imperative paradigms at the same time

  13. 1 week ago
    Anonymous

    reminder that every language is imperative with possibly some functional and OOP features.

  14. 1 week ago
    Anonymous

    imperative programming is for women and women-brained gay homosexuals playing house and pretending it's their time to yell orders and tell something (the computer) what to do

  15. 1 week ago
    Anonymous

    Erlang is the best language.

    • 1 week ago
      Anonymous

      I really like Erlang but struggle to find appropriate applications for it. But I really enjoy writing and working with OTP applications and the very rigid structure of them. It such a well designed language and development platform, sadly it is quite obscure

      • 1 week ago
        Anonymous

        >I really like Erlang but struggle to find appropriate applications for it.
        fud.
        whatsapp and discord exist.

        • 1 week ago
          Anonymous

          Whatsapp has been rewritten in another language (cpp?)

  16. 1 week ago
    Anonymous

    Why not use both?

    • 1 week ago
      Anonymous

      In the same project? Why would you do that?

      • 1 week ago
        Anonymous

        all modern programming languages are multi-paradigm.
        map, apply, filter is a lot easier than verbose loops.

        • 1 week ago
          Anonymous

          Haskell is purely functional.

          • 1 week ago
            Anonymous

            it's not.
            do { putStr "Hello"
            ; putStr " "
            ; putStr "world!"
            ; putStr "n" }

          • 1 week ago
            Anonymous

            What is this moronic do-while?
            What is this fricking bullshit?

          • 1 week ago
            Anonymous

            It's not do-while, it's just syntactic sugar to make code more readable.
            While zoomie languages like Rust want to look as hard as possible, Haskell goes the extra mile to make it easy to read. You should give it a go.

          • 1 week ago
            Anonymous

            ML isn't actually useful, so Haskell breaks the pure FP part of it to make it useful. This makes it no longer safe and no longer pure FP, and it's clunkier to use than other languages, which is why almost nobody uses Haskell.

          • 1 week ago
            Anonymous

            That's a monadic operation, anon.
            https://en.wikibooks.org/wiki/Haskell/do_notation
            Your expression is equivalent to
            putStr "Hello" >> putStr " " >> putStr "world!" >> putStr "n"

            The fact that it looks familiar doesn't make it imperative. Haskell is often sold as a hard language, but it's actually pretty friendly.

            Also, Haskell isn't often written like that. consider:
            do
            putStr "Hello"
            putStr " "
            putStr "world!"
            putStr "n"

            As that is significantly prettier.

          • 1 week ago
            Anonymous

            are you denying that do-notation is imperative style? it clearly is imperative.

          • 1 week ago
            Anonymous

            It isn't imperative, objectively.
            Once again: just because it is readable (as opposed to super hard as Haskell has a reputation for) doesn't make it imperative.

          • 1 week ago
            Anonymous

            so Scala/F aren't functional because underneath it's actually Java/C#?

          • 1 week ago
            Anonymous

            Where did I say any of that?

          • 1 week ago
            Anonymous

            you're clearly moronic and don't know what imperative means

          • 1 week ago
            Anonymous

            Monads are still purely functional.

          • 5 days ago
            Anonymous

            imperative code is purely functional because it simply produces machine code which has no side effects until interpreted by the CPU

          • 5 days ago
            Anonymous

            Filtered by monads, eh?
            Sad! Many such cases.

  17. 1 week ago
    Anonymous

    most algorithms break down naturally into C style code
    functional is okay though, dont hate on lisp trannies

  18. 1 week ago
    Anonymous

    giwtwm

  19. 1 week ago
    Anonymous

    filter'd

  20. 1 week ago
    Anonymous

    yay haskell!

    • 1 week ago
      Anonymous

      If they weren't, Haskell wouldn't be the most influential language of the last decades
      >"functional methods", also known as intuitive way of doing operations, were added to every language
      >lambdas became so popular even a python dev knows what they are
      >everyone's favorite villain, Rust, is strongly influenced by functional
      >currying is becoming more popular, having already been adopted by JavaScript
      >Elm, which is very strongly inspired by Haskell, inspired the most popular frontend frameworks such as React and Vue

      Most courses don't teach functional because teachers are lazy fricks who just wanna teach the same thing forever. Back in my uni days the professors didn't even wanna teach Python or JavaScript, let alone Haskell.

      Haskell won't get you a job.

      • 1 week ago
        Anonymous

        It did but not a Haskell job.

        • 1 week ago
          Anonymous

          >It did
          >not a Haskell job
          So, it didn't.

          • 1 week ago
            Anonymous

            I learned a skill.
            I got a job because of that skill but I don't use that skill at the job.
            The skill didn't get you the job because you don't use it at the job.

            He just said he got the job because of knowing Haskell. It's like hiring a computer programmer because you want the skills and methods of a programmer but not to do programming.

      • 1 week ago
        Anonymous

        That's how good it is. You don't even need to pay people to program in Haskell.

  21. 1 week ago
    Anonymous

    >Functional programming languages
    >overrated
    How can they be overrated if no one is using them?

  22. 1 week ago
    Anonymous

    Please. More young asian hotties in skirts.

  23. 1 week ago
    Anonymous

    I'm convinced that 99.99% of functional programmers are vaccinated. It's the most vaxxmaxxed programming idea I can think of.

    • 1 week ago
      Anonymous

      I'm convinced you're stuck in 2021 and can't deal with the fact the rest of the world has moved on, having fun and going out again, while you're still a sad lonely loser blaming his misery on the government to avoid having to admit you're just unpopular.

  24. 1 week ago
    Anonymous

    and CPUs use registers and program counters

  25. 1 week ago
    Anonymous

    By the way, what did you make with Haskell language?

  26. 7 days ago
    Anonymous

    Why is recursion hard, again?

    • 7 days ago
      Anonymous

      When people are taught imperative, they're taught to never ever ever ever use recursive because it's slower.
      This trauma-based experience causes mental blockages on imperative developers, who can't even start to think about recursive.

    • 7 days ago
      Anonymous

      Because it is abstract. People generally think in terms of lists of steps and when that list can become arbitrarily nested into itself, obscuring same values on multiple layers it gets confused.
      To understand recursion you have to learn to think in terms of invariants and contracts.

      • 7 days ago
        Anonymous

        >confused
        Confusing*

      • 7 days ago
        Anonymous

        >Because it is abstract. People generally think in terms of lists of steps
        well, one of the first things people learn (counting) is defined recursively so maybe it's how it's presented

        • 7 days ago
          Anonymous

          It is defined recursively in set theory which is not how people naturally think of numbers and sizes.

    • 6 days ago
      Anonymous

      to understand recursion you must first understand recursion

  27. 7 days ago
    Anonymous

    llvm eliminates mutation and treats basic blocks as functions to simplify optimization passes, it's pretty practical

  28. 7 days ago
    Anonymous

    Simple argument:
    https://leetcode.com/problems/decode-xored-array/description/

    Imperative
    void decode(int n, int first, int encoded[], int decoded[]) {
    decoded[0] = first;
    for (int i = 0; i < n; ++i)
    decoded[i + 1] = decoded[i] ^ encoded[i];
    }

    Functional
    import Data.Bits (xor)

    decode = scanr xor

    • 7 days ago
      Anonymous

      >scanr
      no clue what that does

      • 6 days ago
        Anonymous

        It's like foldr but returns the list of intermediate values
        scanr (+) 0 [1..5] = [0, 1, 3, 6, 10, 15]
        scanr (*) 1 [1..5] = [1, 1, 2, 6, 24, 120]

        • 6 days ago
          Anonymous

          That is not good example. Demonstrate how functional deals with the problem using recursion or some sort of list comprehension, NOT by using an inbuilt function

          • 6 days ago
            Anonymous

            Not using a higher order function? These functions exist so you don't have to repeat the same recursion pattern all over your code
            >That is not good example. Demonstrate how imperative deals with the problem using a while loop or some sort of goto, NOT by using an inbuilt for statement
            I refuse to write the recursion on grounds that it is inlining the scanr function or the same as translating a for loop to a while loop.
            Also I messed up before and we need scanl to solve the problem
            scanr (+) 0 [1..5] = [15, 10, 6, 3, 1, 0]
            scanr (*) 1 [1..5] = [120, 24, 6, 2, 1, 1]
            I was describing scanl before

          • 6 days ago
            Anonymous

            In that case there is no need to write a loop in cpp either, just import an appropriate function from one of the available libraries and it will do the job

          • 6 days ago
            Anonymous

            I was writting in C. If you want to use a library for functional programming in C++ then what's the point when functional languages are already designed around using these

          • 6 days ago
            Anonymous

            >you want to use a library for functional programming in C++
            No, I don't. I want to use a library or a built in function or something that has already been written by others and has been tested countless times to run safe and efficiently regardless of the language I am using. Demonstrating an in built function vs a hand written loop to solve a basic problem does not earn a finctional language any points

          • 6 days ago
            Anonymous

            >Demonstrating an in built statement vs a hand written goto to solve a basic problem does not earn an imperative language any points [over assembly]

          • 6 days ago
            Anonymous

            C++ can already do functional programming. You don't need anything extra, it's built into the language. It can also do things functional languages can't do, like get shipped in a product that makes money.

          • 6 days ago
            Anonymous

            Counter argument:

            #include <algorithm>

            std::for_each(v.begin(), v.end(), [](int &n) { n++; });

            v' = map (+1) v

          • 6 days ago
            Anonymous

            you can use n += T::size() or n += std::distance(...)

          • 6 days ago
            Anonymous

            The program increases by 1 each element in the vector. The functional version creates a new list with that result. The map function is one of the most significant functions in functional programming

          • 6 days ago
            Anonymous

            Anduril.

          • 6 days ago
            Anonymous

            >some sort of list comprehension
            List comprehensions are built-in functions though. Actually, they're just syntactic sugar for monadic bullshit. From https://en.wikibooks.org/wiki/Haskell/Understanding_monads/List#List_comprehensions:
            threeTurns bd = [ bd3 | bd1 <- nextConfigs bd, bd2 <- nextConfigs bd1, bd3 <- nextConfigs bd2 ]

            is equivalent to
            threeTurns bd = do
            bd1 <- nextConfigs bd
            bd2 <- nextConfigs bd1
            bd3 <- nextConfigs bd2
            return bd3

            Which, in turn, is equivalent to:
            threeTurns bd = nextConfigs bd >>= (bd1 -> nextConfigs bd1 >>= (bd2 -> nextConfigs bd2 >>= (bd3 -> return bd3*~~

            tl;dr: you're a dumbfrick, stop invoking a random argument of purity where you can't even draw the line coherently.

      • 6 days ago
        Anonymous

        in Clojure it's called reductions, which is more intuitive if you already know what reduce does.
        ;; Leetcode 1720

        (defn decode-xored-sequence [encoded first]
        (reductions bit-xor first encoded))

        (assert (= [4 2 0 7 4] (decode-xored-sequence [6 2 7 3] 4*~~

        • 6 days ago
          Anonymous

          In normal languages it's called accumulate.

          • 6 days ago
            Anonymous

            std::accumulate in cpp is very different from scan/reductions
            https://en.cppreference.com/w/cpp/algorithm/accumulate

          • 6 days ago
            Anonymous

            >very different
            its reduce. Wtf were they thinking?

  29. 7 days ago
    Anonymous

    So, how fast is Scientific Haskell?

    • 6 days ago
      Anonymous

      Haskell is faster than Go.
      I'm not sure if scientific makes it faster or slower.

  30. 7 days ago
    Anonymous

    If you're wasting time having this "argument" you've already lost.

    If you care about the opinions of basement tranime morons on IQfy, you will always be an unsuccessful hobbyist.

  31. 6 days ago
    Anonymous

    Functional style is the best and only default, no matter the language.
    Well, unless your writing some dirty throw-away hack.

  32. 6 days ago
    Anonymous

    To anyone concerned. One in the picture is a woman named "Alina Latypova" that seems to work for photoshoots on a Patreon page by the name of "vandych"

    • 6 days ago
      Anonymous

      Thanks for the info, anon.
      I'd sequence her monads, if you know what I mean.

  33. 6 days ago
    Anonymous

    As a pajeet with non functional wiener I want to dump coconut oil on her backside and grind my wrinkly balls on it. Can't imagine having regular straight sex

  34. 6 days ago
    Anonymous

    >functional programming isn't popular and won't get you a job
    Wrong. Functional programming is very popular. Functional programming *languages* are not.
    You can do functional programming in any mainstream language: Separate code with side effects from pure code. Model business logic in terms of types and pure functions and separate functions with side effects, and push them to the edges of your application. Do not use shared global state. Do not mutate function arguments. Only use mutation locally within the definition of a function and ensure functions are pure. Do not use object oriented anti-patterns like the builder pattern that are fundamentally imperative.

    Remember that mutation and iteration are perfectly consistent with the principles of functional programming as long as they are locally scoped (See Haskell's ST monad for example), so you don't need to adopt a non-idiomatic style in imperative languages in order to do functional programming.

    • 6 days ago
      Anonymous

      >You can do functional programming in any mainstream language
      Any good examples of such source code for programs that don't just process text through straight pipeline, with branches and "objects"?

    • 6 days ago
      Anonymous

      Correct me if I wrong: in functional languages you can pass a value that can be evaluated if necessary automatically. So how do you make to work the following code in imperative language:
      multiply_by_two(number) {
      number * 2
      }
      , so the number could be both a simple number or a function (lazy evaluated number)?

      • 6 days ago
        Anonymous

        >in functional languages you can pass a value that can be evaluated if necessary automatically
        Technically, no. That's a feature of lazy languages. Haskell happens to be both, but being functional doesn't require that at all; OCaml is functional and eager evaluating.

      • 6 days ago
        Anonymous

        I don't think I understood your question, but your code is simply:
        multiplyByTwo = (2 *)

        in Haskell.
        It will actually run the function the first time your expression actually needs to be evaluated. So, for example, lets say you wanted a list of all even numbers. You could:
        evens = multiplyByTwo <$> [1..]

        which will give you an infinite list of numbers. The list can be infinite because of this lazy evaluation mechanic in Haskell, since each element will only be multiplied by two when you call them. So, for example, if you called:
        head evens -- same as evens[0] in other languages.

        you'll get the first result, so it's computed and returns you the value 2. But until then, it's just a "thunk", aka an instruction like "when the user gets a number from this list, evaluate it by generating the number, starting from 1, then multiplying it by two".

        The concept of "forcing" an evaluation isn't too prominent in Haskell, except maybe when debugging (where you get the :force command on GHCI and whatnot). If you have a specific usecase where it's bothering you, there's a high chance you're thinking imperatively instead of the functional way.

        • 6 days ago
          Anonymous

          Nta, I think what he meant in functional programming a value passed (to be multiplied by two) can be a number but it can also be another function (which should evaluate to a number).

          • 6 days ago
            Anonymous

            if that's the case, then the answer is just the first codeblock.

        • 6 days ago
          Anonymous

          I just don't know how to implement lazy evaluation in imperative languages, I've thought it is functional language feature.
          I had specific usecase when I had a list of values to pass to a function until it return false and the last value required calculation to be found, so it might be good if it was "on demand".

          • 6 days ago
            Anonymous

            I rememer using a javascript library that did lazy evaluation once. You can try looking it up and seeing how they implemented it.

          • 5 days ago
            Anonymous

            >javascript
            No thanks.

          • 5 days ago
            Anonymous

            you just make thunks for lazy evaluation. Look up Effect-ts, its actually a decent intro for people who want to use a mainstream language but have a decent logical structure

          • 6 days ago
            Anonymous

            You can wrap your computation in a datastructure that also has a tag that tells you if that computation is evaluated (weak head normal form) or not.

    • 6 days ago
      Anonymous

      >Do not use object oriented anti-patterns like the builder pattern that are fundamentally imperative.
      OO IS LE BAD!!!!!!!!!!!!11!!!11!

      • 6 days ago
        Anonymous

        I didn't say that. I said not to use OOP anti-patterns. Please use OOP patterns that aren't anti-patterns if they solve your problem. It's just that a lot of OOP design patterns are actually anti-patterns. There's not necessarily any conflict between OOP and functional programming. You can combine techniques from both.

    • 6 days ago
      Anonymous

      This, it's been a long time since OOP languages have been implementing functional concepts, not the other way around.
      People seething at functional programming are jut getting filtered out by recent version of every mainstream language out there.

      • 6 days ago
        Anonymous

        GHC 9.2 came out in 2021 adding picrel.

        • 5 days ago
          Anonymous

          midwit post

          • 5 days ago
            Anonymous

            You overestimate me

        • 5 days ago
          Anonymous

          I haven't tried this.
          Is GHC/HLS really smart enough to differentiate dot compositions from record dots?

          • 5 days ago
            Anonymous

            why would it be difficult? only functions can be composed

          • 5 days ago
            Anonymous

            >why would it be difficult? only functions can be composed
            This is imperative thinking, Haskell thrives on internal consistency. "." is a function that takes two functions as parameters, and returns a new function. It'd be like remapping "+" or "*".

          • 5 days ago
            Anonymous

            You can type case on arity. Maybe it could look okay if
            -XRequiredTypeArguments didn't need quotes around "foo",
            OverloadedLabels #foo is slightly better.

          • 5 days ago
            Anonymous

            >It steals syntax
            gay

            http://web.archive.org/web/20160310052223/https://prime.haskell.org/wiki/TypeDirectedNameResolution
            They were supposed to do it properly.

          • 5 days ago
            Anonymous

            It's over, GHC has fallen.

          • 5 days ago
            Anonymous

            It steals syntax -- if you put a space after the "." it is the usual function composition. HLS loads the file but won't give type directed completions. So I still use lens' TH.

          • 5 days ago
            Anonymous

            >It steals syntax
            gay

        • 5 days ago
          Anonymous

          wouldn't this imply that data records as a concept itself is non-functional? If not, how does accessing their fields become object oriented

          >muh syntax
          by that argument, parenthesis are functional because of LISP

          • 5 days ago
            Anonymous

            It's an example of GHC adding features other languages
            have had forever, so the languages aren't quite converging
            on Haskell.

          • 5 days ago
            Anonymous

            You could always access named fields on an object in Haskell. It's not "GHC adding features", it's "GHC changing it's looks so it's friendlier to non-Haskell developers". Which is a good philosophy, gatekeeping should be done on the intellectual level, not on the syntactical one.

          • 5 days ago
            Anonymous

            The old x{a = (a x){ b= (b (a x)){ c = d }}} instead of the new
            x{a.b.c = d} or x&a.b.c.~d, is a bigger difference than the use
            of TF instead of FD for me.

  35. 6 days ago
    Anonymous

    Intuitive and practical? Yes.
    Unsafe and dangerous? Also, yes.

    Human code is imperfect, "just trust the programmer" is bullshit.

  36. 6 days ago
    Anonymous

    We use thembecause of math and history. The roots of functional programming are in lambda calculus, a system invented by Alonzo Church to disprove the Decision problem. Then Lisp was invented, shit happened and we now have modern functional languages. However the beauty of the mathematics persists. Yeah, Im a fricking nerd.

  37. 5 days ago
    Anonymous

    >Functional programming languages are overrated. Imperative languages are more intuitive and practical.
    people latch on to functional programming because everyone is so traumatized by OOPslop that any meme paradigm that isn't OOP is like a godsend to them

    • 5 days ago
      Anonymous

      It's a matter of "who do you want designing your systems?"
      OOP means no-code middle managers, Functional means nerd mathematicians.
      Given we're at a competency crisis, everyone just wants the no-coders to frick off.

      • 5 days ago
        Anonymous

        mathbois suck at programming doe
        desperately so

        • 5 days ago
          Anonymous

          At least they code.

          • 5 days ago
            Anonymous

            oh bc you think i dont?
            the reason i have such a low opinion of mathbois is exactly bc i code.
            the moronic shit they do bc hammer->nail way of seeing things.
            and i dont code their moronic shit actually, but i find alternative ways of extracting the information they use hyper-advanceed maths for.

            always start solving a problem with a blank page, if youre a programmer.
            bc you cant trust the morons that came before you.
            its equally true in troubleshooting/repair as in programming

          • 5 days ago
            Anonymous

            >oh bc you think i dont?
            No, I said OOP middle managers don't.
            The fact that you got so defensive means I won't read the remainder of your post, it looks like insecure crap from a half-coder.

          • 5 days ago
            Anonymous

            maybe you should because i was serious
            and whenever im serious i drop solid gold

        • 5 days ago
          Anonymous

          deep FP is too esoteric for most mathchuds, tbh.

          oh bc you think i dont?
          the reason i have such a low opinion of mathbois is exactly bc i code.
          the moronic shit they do bc hammer->nail way of seeing things.
          and i dont code their moronic shit actually, but i find alternative ways of extracting the information they use hyper-advanceed maths for.

          always start solving a problem with a blank page, if youre a programmer.
          bc you cant trust the morons that came before you.
          its equally true in troubleshooting/repair as in programming

          Yet again, CSissies displaying their inferiority complex towards Mathchads.

          • 5 days ago
            Anonymous

            math"chads" cant exist without C"sissies"
            speak with respect, homosexual or you will be waiting until the HD of the universe to get your results bc python

          • 5 days ago
            Anonymous

            theoretical PLT is basically all category theory at this point. they're deep in esoterica like any other current year math PhD candidate.

      • 5 days ago
        Anonymous

        deep FP is too esoteric for most mathchuds, tbh.

  38. 5 days ago
    Anonymous

    brainlet take.

    Functional is making software that works, first and foremost. It just happens that the design and theory of pure FP and monad stacks work. Imperative dogshit doesn't. Rust is probably the best evolution to the imperative space by enforcing multiple readers XOR single writer, which surprisingly cleans up a lot of the broken semantics of imperative.

  39. 5 days ago
    Anonymous

    Male

Your email address will not be published. Required fields are marked *