The Best Refactoring You’ve Never Heard Of

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

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

  • @dupersuper1000
    @dupersuper1000 5 ปีที่แล้ว +9

    Despite the audio problems, this is one of the best talks I’ve seen on the topic of continuations and program structure. Thank you for sharing!

  • @Apreche
    @Apreche 5 ปีที่แล้ว +46

    I was extremely close to not finishing this talk because of the audio issues. I was wearing headphones, and the static noises were like stabbing in my ears. Great talk, though.

    • @ashnur
      @ashnur 5 ปีที่แล้ว +6

      Same here, I don't understand why someone haven't had a day to put some slight audio post-processing on this to filter those extremely loud noises...

    • @okjacob
      @okjacob 4 ปีที่แล้ว +12

      youtube-dl -i --youtube-skip-dash-manifest 'th-cam.com/video/vNwukfhsOME/w-d-xo.html'
      ffmpeg -i The\ Best\ Refactoring\ You’ve\ Never\ Heard\ Of-vNwukfhsOME.mkv -filter_complex "compand=attacks=0:points=-80/-900|-45/-15|-27/-9|0/-7|20/-7:gain=5" -c:v copy -c:a libvorbis out.webm

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

      I downloaded it and played it through VLC with its Compressor effect.The values of the sliders I liked are: 0.1 1.5ms 100ms -30dB 9.7:1 10dB 6.7dB.

    • @jonathanwinandy
      @jonathanwinandy 12 วันที่ผ่านมา

      Thanks for telling us

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

    i like how he says DO DO

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

    For everyone who is suffering because of the audio: Easyeffects with noise reduction and autogain makes it sound pretty ok :)

  • @09goral
    @09goral 4 ปีที่แล้ว +1

    I hard it's called "reification", not "defunction …" I can't even repeat it.

  • @AlexDresko
    @AlexDresko 5 ปีที่แล้ว +6

    I can't. I just can't. Please re-record this with better audio and I think it would be stellar.

  • @kaqqao
    @kaqqao 2 ปีที่แล้ว

    Excellent talk. Terrible audio. But excellent talk.

  • @LimmeAlone
    @LimmeAlone 5 ปีที่แล้ว +4

    the cringe @ 24:20 :D

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

    I just want to say this technique is obnoxious. Pretty much the whole point of the this technique would be to apply it to the task of iteratively walking through a tree structure and accumulating a value from it. When this gets brought up on the internet, its always (like this video) walking through a tree structure and NOT accumulating a value or, like other articles, accumulating a value from a sequence structure (like summing a list). Table stakes for this technique to be useful is walking a tree AND accumulating a value - but once you do that, the method shown here just doesn't work - why? because you have 2 different conceptual stacks to maintain (one to maintain position in the tree and one to accumulate the value) and the inlining no longer works the same way and there is just nothing out there that bridges the gap.

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

      Correct!
      Talk is kind of misleading.
      The reason why the tree traversal function prints the traversal path instead of returning it as a list is because it CAN'T accumulate the path and return it.

    • @williamd4866
      @williamd4866 2 ปีที่แล้ว

      ​@@1210divs That's not true! As TJ above mentions, you can accumulate a value like a list through a tree using this technique. The things you end up accumulating together are just represented by functions arguments for the continuation.

    • @1210divs
      @1210divs 2 ปีที่แล้ว

      @@williamd4866 I will believe you if you show me a version of the code from this video that returns the output as a sequence rather than printing it.

    • @williamd4866
      @williamd4866 2 ปีที่แล้ว

      @@1210divs Something like this would accumulate a list in CPS:
      List listTree(Tree tree, Function kont)
      {
      if (tree != null) {
      return listTree(tree.left, (L) -> { return listTree(tree.right, (R) -> { return kont(L + [tree.content] + R); }); });
      }
      else {
      return kont(List());
      }
      }

    • @1210divs
      @1210divs 2 ปีที่แล้ว

      @@williamd4866 at this point, you are no longer using the continuation and doing plain old recursion that will lead to stackoverflow.