Menu
Sign In Search Podcasts Charts People & Topics Add Podcast API Blog Pricing

David Heinemeier Hansson (DHH)

๐Ÿ‘ค Speaker
4269 total appearances

Appearances Over Time

Podcast Appearances

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

It's a number.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

Do you know what?

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

You can add your own methods to that.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

I did, extensively.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

In Rails, we have something called Active Support, which is essentially my dialect of Ruby for programming web applications.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

And I'll give you one example.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

I've added a method called days to the number.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

So if you do five dot days, you get five days in seconds because seconds is the way we set cash expiration times and other things like that.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

So you can say cash expires in five dot days.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

Damn.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

And you're going to get whatever five times 24 times 60 times 60 is or whatever the math is, right?

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

Very humanly readable.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

In a normal programming language, you would type out the seconds and then you would have a little comment above it saying this represent five days.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

Mm-hmm.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

In Ruby, you get to write five days.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

But even better than that, Matz didn't come up with it.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

Matz didn't need the five days.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

I needed that because I needed to expire caches.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

I was allowed by Matz to extend his story with my own chapters.

Lex Fridman Podcast
#474 โ€“ DHH: Future of Programming, AI, Ruby on Rails, Productivity & Parenting

on equal footing, such that a reader of Ruby could not tell the difference between the code Mats wrote and the code that I wrote.