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

Guido van Rossum

๐Ÿ‘ค Speaker
See mentions of this person in podcasts
1189 total appearances

Appearances Over Time

Podcast Appearances

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

An object is basically a pointer to a bunch of memory that contains more pointers.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

Well, not quite, but there are a lot of them.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

So to simplify a bit, we look up in one of the objects, what is the type of that object?

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And does that object type define an add operation?

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And so you can imagine that there is a sort of a type integer that knows how to add itself to another integer.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And there is a type floating point number that knows how to add itself to another floating point number.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And the integers and floating point numbers are sort of important, I think, mostly historically, because in the first computers, you used the sort of the same bit pattern when interpreted as a floating point number had a very different value than when interpreted as an integer.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

The operator is more like...

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

It's an index in a list of functions that the integer type defines.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And so the integer type is really a collection of functions, and there is an add function, and there's a multiply function, and there are like 30 other functions for other operations.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

There's a power function, for example.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And you can imagine that

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

In memory, there is a distinct slot for the add operations.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

Let's say the add operation is the first operation of a type and the multiply is the second operation of a type.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

So now we take the integer type and we take the floating point type.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

In both cases, the add operation is the first slot and multiply is the second slot.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

But...

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

Each slot contains a function, and the functions are different, because the addToIntegers function interprets the bit patterns as integers.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

The addToFloat function interprets the same bit pattern as a floating point number.

Lex Fridman Podcast
#341 โ€“ Guido van Rossum: Python and the Future of Programming

And then there is the string.