The Harry Potter Theory of Programming Language Design

Guido van Rossum, the creator of Python programming language came up with an interesting analogy between writing a series of fiction books and designing a programming language.

Guido loves reading the Harry Potter books, he is very impressed with J.K. Rowling’s idea of picking out a detail from earlier books that at the time was given just to add colour to the story, and gave it new significance.

Guido continues on J.K. Rowling, “she had developed a fairly good idea of what kind of things might eventually happen in the series, but she didn’t have the complete plot lines for the remaining books worked out, nor did she have every detail decided of how magic works in her world.” In a similar vein, I had never thought of iterators or generators when I came up with Python’s for-loop, or using % as a string formatting operator, and as a matter of fact, using ‘def’ for defining both methods and functions was not part of the initial plan either.

Guido on Python : Just like the successive Harry Potter books are required to have “continuity”, successive versions of Python are constrained by pretty serious backwards compatibility requirements.

>> All Things Pythonic

Content Team

The IndicThreads Content Team posts news about the latest and greatest in software development as well as content from IndicThreads' conferences and events. Track us social media @IndicThreads. Stay tuned!

Leave a Reply