Talkshelf
Back to videos

Y Not: adventures in functional programming

Confreaks

53:21 · 2012

YouTube

Study materials

English notes, a quiz, flashcards and a PPT outline are available below the player.

Slides are a PPT outline, not a finished slide deck.

Overview

Jim Weirich's RubyConf 2012 talk derives the Y combinator step by step, live-coding in Ruby lambdas. It builds up an understanding of functional programming and lambda calculus from first principles.

Why HN discusses it

HN recommends it repeatedly as one of the best and most entertaining programming talks, and as the talk that makes the Y combinator click, even for people who do not use Ruby.

Before you watch

You should be comfortable reading functions and simple recursion. Ruby syntax helps, but the central goal is understanding functions that receive and return other functions.

A way to study this video

Pause at each lambda transformation and work through one small input by hand. Keep the original recursive definition beside the changing code so you can explain what behavior is preserved.

Functional programming · Computability & complexity theory · Python, Ruby & scripting languages

HN comments

20 collected comments

Newest first

sva_Strong recommendation

In discussion: Baking the Y Combinator from Scratch

If anyone wants this in a humorous 1 hour format, watch the legendary Jim Weirich (rip) explain it here: [VIDEO] Don't be discouraged that it is in Ruby as the concepts are completely general. Great watch even though I never coded a line of Ruby.

jiripospisilRecommendation

In discussion: Ask HN: What piece of code/codebase blew your mind when you saw it?

Well, .NET's garbage collector certainly springs to mind. Not exactly in a good way. You know you have something special on your hands when GitHub refuses to show you a highlighted version of a hand written C++ file ( [LINK] ). Other than that, I remember my mind was blown a few times while watching Jim Weirich's presentation on functional programming all those years ago ( [VIDEO] ).

Showing 5 of 20 comments