Functional programming design patterns by Scott Wlaschin

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ต.ค. 2024

ความคิดเห็น • 133

  • @fnvtyjkusg
    @fnvtyjkusg 8 ปีที่แล้ว +264

    That guy laughing is having the time of his life

    • @Mrgreatestfreakout
      @Mrgreatestfreakout 7 ปีที่แล้ว +9

      best moment of his life

    • @communistpropagandist4608
      @communistpropagandist4608 6 ปีที่แล้ว +10

      This is a seriously funny talk

    • @Evan490BC
      @Evan490BC 5 ปีที่แล้ว +30

      Yes, he is a FUNctional programmer.

    • @Evan490BC
      @Evan490BC 5 ปีที่แล้ว +3

      @A. B. Stone Haha, I think anamorphisms got him high (pun intended).

    • @rollingc2013
      @rollingc2013 2 ปีที่แล้ว +1

      I found him laughing funny 🤣

  • @jonathanwatmough
    @jonathanwatmough 7 ปีที่แล้ว +52

    This is by far the best functional programming talk I have ever seen.
    Brilliant work.

  • @LizardanNet
    @LizardanNet 8 ปีที่แล้ว +59

    Best talk on FP I've seen. And I've seen a lot. Thank you Sir.

    • @enmodo
      @enmodo 8 ปีที่แล้ว

      I agree! If you are new to the field you'll want to stop and think about stuff here and there, but he really does do a very nice gradual introduction of FP and get to some advanced topics.

    • @DjLeonSKennedy
      @DjLeonSKennedy 7 ปีที่แล้ว

      you're wrong

    • @privetvastutnestoyalo2339
      @privetvastutnestoyalo2339 7 ปีที่แล้ว +3

      Юрий Яковенко
      What would you recommend for an introductory lesson on FP?

  • @WateryIce54321
    @WateryIce54321 7 ปีที่แล้ว +19

    Scott's explanation of mapping, functors, and monads is gold. I've read quite a few tutorials and videos in an effort to better understand Haskell, but couldn't quite understand the overall picture until watching this.

  • @DrewRoses2
    @DrewRoses2 4 ปีที่แล้ว +8

    One of the best intros do FP, hands down. Every concept is explained in a clear, pragmatic way and on top of that Scott has a great sense of humor!

  • @stas4112
    @stas4112 2 ปีที่แล้ว +6

    While I have quite a long way to go until I can properly re-program my brain to think more functionally, this talk really helped spark a couple light bulb moments. Some of the ideas I actually ran back to my company's OOP Enterprise code and implemented, funny enough. Great video, hopefully a couple more of these and I'll have my head wrapped around this crazy functional world :)

  • @leminh111a
    @leminh111a 8 ปีที่แล้ว +7

    I'm currently learning Haskell and after watching many presentations, many books, many lectures, I find this to be the best introduction to functional programming. This talk generalizes, provides the big picture of functional programming. Many light bulbs popped up on my head when I was listening to this.

  • @ChatterboxBS1
    @ChatterboxBS1 8 ปีที่แล้ว +24

    Best talk I have seen in a long long time

  • @yarilich544
    @yarilich544 หลายเดือนก่อน

    Enjoyed the talk very much, especially the humor. I came here as a professional Scala developer after an interview where I failed to enumerate functional programming patterns I use. I leave kinda disappointed because I use most of these patterns daily anyway. I guess when I'm asked to enumerate functional programming patterns I use again, I'm just going to use the fancy names like continuations, monadic bind and functors.

  • @romanemul1
    @romanemul1 6 ปีที่แล้ว +1

    basically many presenters which i have seen so far started introduction into FP same way as the last statement. "Monad is just a monoid....." together with bunch of lines with FP stuff while repeating same words over and over. Monoids, monads, functors, endomorphisms without explaining single word. This guy made this stuff much more clearer. Very good presentation.

  • @mpi6918
    @mpi6918 8 ปีที่แล้ว +7

    Clearest conceptual presentation on FP I have seen so far

  • @MrSenseofReason
    @MrSenseofReason 8 ปีที่แล้ว +3

    It's just amazing that i can find this full length lecture online! Thank you for the upload, the internet is incredible.

  • @privetvastutnestoyalo2339
    @privetvastutnestoyalo2339 7 ปีที่แล้ว +3

    Thanks for this talk, FP is finally starting to make sense for me.

  • @ChrisKunzler
    @ChrisKunzler 8 ปีที่แล้ว +28

    I"m only seven minutes in, but I have to say the speaker is hilarious. He has a great since of humor.

  • @dasprince0
    @dasprince0 3 ปีที่แล้ว +1

    Probably the best talk I've watched so far on FP! Explained everything clearly!

  • @dexio85
    @dexio85 7 ปีที่แล้ว +1

    Finally I started to understand FP. Thanks for this presentation. Much better than a lot of those yapping and preaching ones on the TH-cam.

  • @artronics
    @artronics 8 ปีที่แล้ว +4

    Wow, in an hour you explained concepts that I was struggling to grasp for almost one week! Best talk on FP

  • @JMROMERO95
    @JMROMERO95 8 ปีที่แล้ว +7

    Best talk ever about functional programming! Thank you so much

  • @NikolaiAleksandrenko
    @NikolaiAleksandrenko 5 ปีที่แล้ว +1

    Best talk on FP I've seen. Thank you.

  • @TimTeatro
    @TimTeatro 7 ปีที่แล้ว +5

    Beautiful talk. Probably the best introductions I've seen. And I think the comments under-rate the humour. I thought it was funny as hell.
    One NB (which the speaker probably is well aware of): 56:37 all monoids are either groups or semigroups, identity element or no. A group is a monoid with inverses. For example, integers under addition, (Z, +), form a group, where the inverses are the negative numbers: 5 + (-5) = 0. However, if I take only non-negative integers with addition ( { z in Z | z >= 0 }, + ), there are no inverses so I get a monoid, which is called a semigroup because it doesn't entirely satisfy the group axioms. But notice, it still has an identity element (that is, zero).
    So, it isn't wrong, but it isn't entirely correct to say that a monoid with no identity is called a semigroup, since monoids WITH an identity element may also be called semigroups.

    • @ashleysnow9468
      @ashleysnow9468 6 ปีที่แล้ว

      Very well Indeed. I must agree with this amalgamation of information in integration of this mysterious calculation. Indeed this is a superb observation indeed.

  • @sguoqing
    @sguoqing 8 ปีที่แล้ว +1

    This is great to get it clear for critical FP concepts from this video

  • @TheR971
    @TheR971 5 ปีที่แล้ว

    That's a very first CS semester talk. And give this man some water!

  • @iraasta
    @iraasta 8 ปีที่แล้ว +3

    Really great talk. Easy way of explaining very advanced concepts. I wish I've seen this video earlier

  • @adsa4269
    @adsa4269 7 ปีที่แล้ว +1

    FP presentation in a pragmatic way! awesome!

  • @PRT976
    @PRT976 8 ปีที่แล้ว

    Hey this is obviously the best explanation of Monoids (in human language).

  • @wanderlustfunk
    @wanderlustfunk 26 วันที่ผ่านมา

    i was numb through this, he really got me with that 1 + 0 = 0 + 1

  • @FrVle
    @FrVle 8 ปีที่แล้ว +4

    Amazing! Thanks for the upload this was extremely useful!

  • @datpip
    @datpip 7 ปีที่แล้ว

    Great talk. Thanks for the time and effort put into this.

  • @PulpFreePress
    @PulpFreePress 6 ปีที่แล้ว

    Still a great presentation even today. Thanks for posting.

  • @abdulrahmansattar2873
    @abdulrahmansattar2873 8 ปีที่แล้ว +6

    Cool talk!

  • @KubeckiOfficial
    @KubeckiOfficial 6 ปีที่แล้ว +1

    Strait to the point - I loved it! :)

  • @linhe6729
    @linhe6729 6 ปีที่แล้ว

    Thank you for this great talk!

  • @sbenjamis
    @sbenjamis 7 ปีที่แล้ว

    Very well done and wonderfully clear.

  • @netional5154
    @netional5154 7 ปีที่แล้ว

    This was exceptionally good.

  • @user-sv7bx6gn8n9
    @user-sv7bx6gn8n9 7 ปีที่แล้ว

    Simple words to demonstrate hard things!

  • @NicolasJulioFlores
    @NicolasJulioFlores 5 ปีที่แล้ว +2

    Alright I'm sort of confused. At 23:19 he talks about how he could rewrite the interface in F# using one function... If the interface is already only one method, and that method only accepts int and returns int. Could he not have just done the same thing in the original language by just ... scrapping the interface?

  • @monquixote
    @monquixote 8 ปีที่แล้ว +2

    Brilliant talk and very funny.

  • @thingsiplay
    @thingsiplay ปีที่แล้ว

    I'm more interested into Haskell than F#. This talk is generic enough to be understood. Thank you, very well done.

  • @dn5426
    @dn5426 7 ปีที่แล้ว +1

    Feel motivated to learn FP now. Any project ideas that excel with FP?

  • @mortenbrodersen8664
    @mortenbrodersen8664 7 ปีที่แล้ว

    Excellent talk!

  • @blahbl4hblahtoo
    @blahbl4hblahtoo 8 ปีที่แล้ว +254

    Man, that one dude thinks this was really, really, funny.

    • @adambowman1161
      @adambowman1161 8 ปีที่แล้ว +44

      +blahbl4hblahtoo he makes the the jokes much funnier than they actually are.

    • @mahendarsparrow
      @mahendarsparrow 8 ปีที่แล้ว +29

      +blahbl4hblahtoo he's probably stoned

    • @infinitesimotel
      @infinitesimotel 8 ปีที่แล้ว +4

      He might have been a hired cachinator.

    • @jpphoton
      @jpphoton 7 ปีที่แล้ว +6

      one of those head hunter infiltrators.

    • @refreshious
      @refreshious 7 ปีที่แล้ว +5

      Laughing dude looks up to the guy and is saying "I get the jokes which makes me smart too". When it's just a paradigm

  • @jwj410
    @jwj410 7 ปีที่แล้ว

    Excellent talk

  • @bartekkalemba8281
    @bartekkalemba8281 8 ปีที่แล้ว +4

    Well..... THANK YOU!

  • @kodekata
    @kodekata ปีที่แล้ว

    There is a problem with the technique used at 57:40.
    The Order total is wrong when the code is refactored.
    Original: 2 * 19.98 + 1 * 1.99 + 3 * 3.99 = 53.92
    Refactored: 6 * 25.96 = 155.76

  • @zeroxcub
    @zeroxcub 8 ปีที่แล้ว

    Great talk, thanks

  • @JMiskovsky
    @JMiskovsky 3 ปีที่แล้ว

    Wow, great! I think that FP patterns combine nicely with DB in 6th normal forms, since you call functions with included another functions - > You get benefits of right definition what to call. And in some super fast DB where only value pairs are possible you could get super fast code. There is Convergence I think.

    • @ivanplyusnin3292
      @ivanplyusnin3292  3 ปีที่แล้ว +2

      Nice catch. You may try to implement a sample project since practice is the best judge for ideas. Try look at www.anchormodeling.com/about/ for some inspiration.

    • @JMiskovsky
      @JMiskovsky 3 ปีที่แล้ว

      @@ivanplyusnin3292
      I thought about using Key Value pair DB like REDIS or MemcacheDB. What do you think?
      Tools you provided link to might be way to MODEL DATA -> USE Key value DB in 6NF WITH Functional programming .
      Only think is how to store precipitant data.
      th-cam.com/video/W2Z7fbCLSTw/w-d-xo.html

  • @akbaralam8683
    @akbaralam8683 6 ปีที่แล้ว

    That guy man, I guess he is a best friend of the speaker.

  • @bojanmatic024
    @bojanmatic024 6 ปีที่แล้ว +1

    You can't really have something like NonIntegerZero in most languages. This is sort of the limit of even the most powerful static type systems. It is the domain of dependent typing but then you have to give up Turing-completeness...

    • @mxBug
      @mxBug 6 ปีที่แล้ว

      no, dependently typed languages like F* and Idris are still Turing complete! diverging (non-terminating) functions are allowed, as long as they're marked as such.

  • @yelgabs
    @yelgabs 8 ปีที่แล้ว +11

    That coughing is killing me. Much louder than the talking volume.
    Can't hear him talk if I reduce the volume, but I get attacked by coughs if I turn it up.

    • @infinitesimotel
      @infinitesimotel 7 ปีที่แล้ว +11

      If it kills you, you will end up buried in a coughin.

  • @robertomartinez8966
    @robertomartinez8966 7 ปีที่แล้ว +2

    In minute 16:00 he talks about a NonZeroInteger that fails at COMPILING TIME, how can we do this in F#? I cannot find anyway to do that.

    • @robertomartinez8966
      @robertomartinez8966 7 ปีที่แล้ว +2

      I post a question in Stackoverflow(stackoverflow.com/questions/45626196/defining-a-non-zero-integer-type-in-f/45635075#45635075) about this matter and all responses revolve around creating a NonZeroInteger type that throws an exception when a zero is passed to constructor, but this can be achieved with any OO programming language so why the video's author claims this as a F# or a functional programming goodness. Honestly I feel tricked.

    • @mxBug
      @mxBug 6 ปีที่แล้ว +3

      F* has refinement types that can do exactly what you're thinking of (among many other static typing features), and can be reduced to F#. www.fstar-lang.org/
      But I think you're missing the forest for the trees. Even that example you linked shows how sum types like Option can be used to handle errors _without_ exceptions. If you watch the rest of the talk (or more relevantly, the follow-up talk on error handling vimeo.com/97344498 ) there are many examples of why that property is useful.

  • @gpnryou
    @gpnryou 3 ปีที่แล้ว +2

    The only reason mathematicians got there first is because they didn't have computers way before we didn't.

  • @pandiatonicism
    @pandiatonicism 5 ปีที่แล้ว

    I came for the FP, I stayed for the LOLs.

  • @whatever63644
    @whatever63644 5 ปีที่แล้ว

    this is what happens when you invite a standup comedian to a technical conference

  • @mgilgar
    @mgilgar 7 ปีที่แล้ว

    really good

  • @richerite
    @richerite 5 ปีที่แล้ว

    Is there no straightforward way to define NonZeroInteger type?

  • @bocckoka
    @bocckoka 7 ปีที่แล้ว

    Top floor is for Martin-Löf, Idris, Agda, Coq and the like.

  • @alijavadi6278
    @alijavadi6278 8 ปีที่แล้ว

    it is a good video and it gives me some incentive to continue working on JavaScript.

  • @codegully_channel
    @codegully_channel 8 ปีที่แล้ว

    awesome..

  • @PaulWalker-lk3gi
    @PaulWalker-lk3gi 7 ปีที่แล้ว

    I took a lot from this but def started to lose me around 42:00 (although that does look a lot like error handling in node)

  • @Noble_1776
    @Noble_1776 6 ปีที่แล้ว

    Does List.fold loop or is it a recursive higher order function? He says loop in the video but I am guessing that is just a hiccup and he means recursion but I don't know f#. From my understanding a big part of functional programming is treat data as immutable, so no loops. Is that right?

    • @REL1C
      @REL1C 3 ปีที่แล้ว +1

      There is nothing wrong with loops in functional programming. Recursion is usually just a loop anyway. Look at the source for List.fold for an answer to your question. github.com/dotnet/fsharp/blob/main/src/fsharp/FSharp.Core/list.fs#L216-216

  • @NonTwinBrothers
    @NonTwinBrothers ปีที่แล้ว

    The captions at 30:55 lmao

  • @xmorse
    @xmorse 6 ปีที่แล้ว

    brilliant

  • @pneptun
    @pneptun 7 ปีที่แล้ว

    1) 43:05 I didn't get the error handling part - he showed the code before and after error handling, it was the same, ok great soooo - where was the error handling? where did all the different error messages go? they were different for each error so surely you had to put them somewhere... highly misleading (he suggested 200% extra lines just for error handling, 0 extra lines for error handling in F# - that's what i'm challenging: the code did go into the monads sooo ... it's not like it disappeared ;)
    2) 42:26 he got the promises wrong - the promises ACTUALLY SOLVE the pyramid of doom the exact same way bind does :-D he presented it as if they just rewrote it in different words.

  • @DarrylJordanOLW
    @DarrylJordanOLW 8 ปีที่แล้ว

    Stay tuned for ES8: Optional Static Typing has been proposed.

  • @nvbkdw
    @nvbkdw 7 ปีที่แล้ว

    who is the guy with wide laughter? since he get every point, must be another FP expert

  • @knedlsepp
    @knedlsepp 8 ปีที่แล้ว +1

    plus1 and subtract42 are not endomorphisms.

    • @ElvianEmpire
      @ElvianEmpire 8 ปีที่แล้ว

      what are they then? endomorphism means same input and output type, which they have.

    • @knedlsepp
      @knedlsepp 8 ปีที่แล้ว +1

      Well, in the category of sets they are endomorphisms. But they don't preserve the neutral element in the sense that:
      `1 = plus1(0+0) =!= plus1(0) + plus1(0) = 2`, which means you can't use any kind of map-reduce approach. So I don't quite get the point he is trying to make at 1:03:04, as this definitely is not something that can be done "in parallel". (In the end he is more explicitly talking about "endofunctors" instead of "endomorphisms", which would be a better word for describing "plus1" and "subtract42".)

    • @Ghi102
      @Ghi102 7 ปีที่แล้ว

      Are you sure? I would think that your example is not one of preservation of order. The correct example would be if this is valid:
      plus1(0 + plus1(0)) + plus1(0) which is equal to plus1(0) + plus1(0 + plus1(0))
      I'm not sure, but that's how I understood it.

    • @knedlsepp
      @knedlsepp 7 ปีที่แล้ว

      I'm actually not so sure anymore. I know endomorphisms from an algebraic background: mathworld.wolfram.com/Endomorphism.html
      It might be that there is a bit of a discrepancy between what endomorphism means in the context of functional programming compared to a group/module/ring/vector space-endomorphism. At least in these contexts it wouldn't be considered an endomorphism.

    • @knedlsepp
      @knedlsepp 7 ปีที่แล้ว

      If by endomorphism it is meant "endomorphism in the category of sets" then I guess that they are endomorphisms then. But I still don't see what that buys us. That's a pretty weak requirement and I don't get how this provides us any benefit for parallelization.

  • @refreshious
    @refreshious 7 ปีที่แล้ว

    For years everything is input-> process-> output

  • @engelshentenawy
    @engelshentenawy 7 ปีที่แล้ว +1

    I'm laughing not cuz it was that funny , but because that guy really thought it was ..

  • @eNSWE
    @eNSWE 8 ปีที่แล้ว

    is a monoid actually just an algebraic ring?

    • @Magnetohydrodynamics
      @Magnetohydrodynamics 8 ปีที่แล้ว +3

      +eNSWE the multiplicative operation only, yes. There is a forgetful functor from Ring to Monoid, which forgets the abelian additive group of a ring.

    • @LIB3RTARIAN1337
      @LIB3RTARIAN1337 8 ปีที่แล้ว +1

      +eNSWE In addition to what Magnetohydrodynamics said, you can think of a ring as a set R with operations * and + denoted as (R, +, *) where:
      1. R under addition is an abelian group
      2. R under multiplication is a monoid
      3. Multiplication is distributive over addition
      These 3 characteristics are much easier for remembering what a ring is, given that you know what the underlying structures are. In fact, these structures (abstract algebraic structures) arose largely out of linear algebra from relaxing the axioms of fields and vector spaces.
      I started learning abstract algebra before number theory so this is actually how I remember what a ring is, instead of the 8+ axioms normally given in an introduction to rings.
      Anyway, it is pretty easy to remember all the axioms just from knowing the group axioms and a couple of generalizations:
      A group is a set G with an operation where:
      1. G is closed under that operation
      2. The operation is associative
      3. There is an identity element for the operation in G (if we take the operation to be + and identity to be 0, then for every x in G, x + 0 = 0 + x = x)
      4. Every element in G has an inverse for the operation (if we take the operation to be + and the identity to be 0, then for every x in G, there exists a y so that x + y = y + x = 0)
      If you take 1 and 2, you get a semigroup. If you take 1,2,3 you get a monoid. All four gives you a group. If the operation is commutative, we say we have a commutative or abelian group.
      You can also add commutativity to the operation for a strict monoid (something that is a monoid, but not a group, like multiplication in integers) to get a commutative monoid. If you do this for the multiplication operation of a ring, you get a commutative ring. If you also add inverses to the multiplication (except for 0), it becomes an abelian group (for its non-zero elements) and we can then say that (R,+,*) is a field.
      How you remember this stuff will largely depend on the order you learn it in, but these concepts are all very much algebraically and historically related!

  • @crist2000a
    @crist2000a 3 ปีที่แล้ว

    I do not follow why some people are so thrilled by FP? At some point it looks simple but I see limitations mostly.

    • @ivanplyusnin3292
      @ivanplyusnin3292  3 ปีที่แล้ว

      There is no silver bullet unfortunately, all programming paradigms has its own pros and cons. In the end it depends on project, administrative politics, area of use, your team, your level, tasks etc. But it is better to be aware of all of them in order to choose the most appropriate one in your current situation. P.S. Yeah, seems like functional programming has its own benefits, compared to OO style for example and vice versa.

  • @felipevaldes9168
    @felipevaldes9168 8 ปีที่แล้ว

    what? it DOES work in javascript:
    $ node
    > 1+0
    1
    > 0+1
    1

    • @Eugensson
      @Eugensson 8 ปีที่แล้ว

      I think some person from the audience mentioned that the second one might not resolve to true (0+1=1). I do not know if he is right though.

    • @ufg22
      @ufg22 7 ปีที่แล้ว +2

      I think he was probably referring to the 1 + 2 = 3 on the slide, and confusing that with the fact that in Javascript, 0.1 + 0.2 === 0.30000000000000004 due to floating point precision ¯\_(ツ)_/¯

  • @solmateusbraga
    @solmateusbraga 2 หลายเดือนก่อน

    The guy laughing like a hyena at 4:20... I mean, 4 20. Joke makes itself.

  • @fartzy
    @fartzy 7 ปีที่แล้ว +1

    Is it just me, or does anyone else think exceptions are kind of nice. Why do the extra work, everyone knows what divide by zero exception means. Handling exceptions with try catch and doing some custom logic is hardly a new concept.

    • @bocckoka
      @bocckoka 7 ปีที่แล้ว

      that's really not the question. the question whether or not to compiler enforces that side effects are handled.

    • @fartzy
      @fartzy 7 ปีที่แล้ว +1

      doesnt the program exit if you want it to

  • @pwnDonkey
    @pwnDonkey 7 ปีที่แล้ว

    seems like youre just kicking the can down the road with exceptions in alot of ways. Also, dont you have to know how the function is implemented if you are passing for example "Divide(top, bottom, ifZero, ifSuccess)". Youre basically saying you know that zero is a special case, why not just check for it before you pass it.

    • @stopmotiontacos
      @stopmotiontacos 6 ปีที่แล้ว

      pwnDonkey he's just demonstrating the principle. Sure maybe it was a bad example just don't get lost in the application

    • @mxBug
      @mxBug 6 ปีที่แล้ว +1

      the argument could be called ifFailure and would not lose any semantics. there's no need to know how it's implemented, and the type signature _forces_ you to have a contingency plan, rather than throwing exceptions that have no guarantee of being caught, or returning invalid or "magic number" answers that have no guarantee of being interpreted correctly.

  • @MercedeX7
    @MercedeX7 6 ปีที่แล้ว +3

    what's with that hohohahaha?
    🤔

  • @thecount25
    @thecount25 6 ปีที่แล้ว

    The equivalent of Objects in Functional programming are actually not functions, it's actors.

  • @no_more_free_nicks
    @no_more_free_nicks 7 ปีที่แล้ว +1

    Functional patterns allow you to accumulate a lot of calories in your body.

  • @billyclabough9835
    @billyclabough9835 6 ปีที่แล้ว

    I made it to ivory tower before audience laughter became to annoying

  • @ian3084
    @ian3084 5 ปีที่แล้ว

    This was a very good presentation.
    But the more i watch/learn about FP the more holes i discover.
    For very small benefits we add so many not necessary things, complexity, dependencies, ugliness of code, non-uniformity, potential for errors ...

    • @bmbiz
      @bmbiz 4 ปีที่แล้ว +2

      Except it's the exact opposite of most of those things. Keep watching/learning.

  • @KennethKasajian
    @KennethKasajian 4 ปีที่แล้ว

    you talk about how object-oriented is bad in the example where methods that take a string, expecting an e-mail address, could pass in some other string that's not an e-mail address such as a last name, to present the benefit of value-objects.
    but then you talk about how interfaces aren't needed in F# because you can functions compatible based on structure.
    It's a little bit misleading because in object-oriented programming, interfaces are the way you give data stronger type-safe guarantees.
    The interface from OOP which you seem to down-play *is* the primary mechanism to provide a type .

  • @TJ-hs1qm
    @TJ-hs1qm 10 หลายเดือนก่อน

    Joker ??? 😂

  • @koko0riginal
    @koko0riginal 7 ปีที่แล้ว

    I have to say i don't understand why go functional, when you just do OOP with functions.
    partial functions are objects of a class with one function. you have state. calling the same function twice might not produce the same results.
    i really can't see what's the advantages of using functional programming if you go this way.

    • @BrettRowberry
      @BrettRowberry 6 ปีที่แล้ว +1

      Calling the same function with the same inputs twice yields the same result. In C# for example, static methods also yield the same output for given inputs. Where you get into trouble with OOP is in instance methods where the state of the object does impact the output.

  • @krb3141
    @krb3141 7 ปีที่แล้ว

    The laughing dude and the constant mic'ed throat clearing make this otherwise great looking video difficult to watch.

  • @chrisvouga8832
    @chrisvouga8832 5 ปีที่แล้ว +1

    Next time take some cough medicine before you give a talk 😐

  • @bobweiram6321
    @bobweiram6321 3 ปีที่แล้ว +1

    Functional programming is all BS, summed up as f(BS)! None of these talks illustrate clearly how to use functional programming to solve a the types of problems developers need to solve. They always cherrypick some mathematical problem like Fibonacci sequences. They also emphasize brevity of the code without discussing metrics we really care about such as performance. It's all intellectual masturbation.