# Raymond Hettinger

Ruminations on Computers, Programming and Life

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## Python's super() considered super!

DevFeed: [Python's super() considered super!](<https://devfeed.tech/articles/python-s-super-considered-super-21697.md>)

Original publisher: [Read original article](<https://rhettinger.wordpress.com/2011/05/26/super-considered-super/>)

Author: rhettinger

Published: 2011-05-26T16:15:42Z

Content type: article

Language: en

Sources: [Raymond Hettinger](<https://devfeed.tech/sources/raymond-hettinger.md>)

Topics: [Python](<https://devfeed.tech/topics/python.md>)

Tags: [algorithms](<https://devfeed.tech/tags/algorithms.md>), [dict](<https://devfeed.tech/tags/dict.md>), [documentation](<https://devfeed.tech/tags/documentation.md>), [inheritance](<https://devfeed.tech/tags/inheritance.md>), [logging](<https://devfeed.tech/tags/logging.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [python](<https://devfeed.tech/tags/python.md>)

### AI overview

The excerpt shows `super()` as runtime-computed delegation that follows a class's method resolution order. In a `LoggingDict` subclass, `__setitem__` logs an update, then calls `super()` to perform it. Compared with hardwiring `dict.__setitem__`, this avoids naming the delegate class, so changing the base class can update delegation automatically. The excerpt also demonstrates using inheritance order to combine `LoggingDict` with `OrderedDict`, producing a logging ordered dictionary without modifying either class. It introduces this as a practical mental model and mentions examples in Python 2 and Python 3 syntax; the supplied text ends during the inheritance example.

### Source excerpt

If you aren't wowed by Python's super() builtin, chances are you don't really know what it is capable of doing or how to use it effectively. Much has been written about super() and much of that writing has been a failure. This article seeks to improve on the situation by: providing practical use cases giving [...]

## Open Source Challenge: Open Your Source, More

DevFeed: [Open Source Challenge: Open Your Source, More](<https://devfeed.tech/articles/open-source-challenge-open-your-source-more-21696.md>)

Original publisher: [Read original article](<https://rhettinger.wordpress.com/2011/01/28/open-your-source-more/>)

Author: rhettinger

Published: 2011-01-28T13:15:59Z

Content type: opinion

Language: en

Sources: [Raymond Hettinger](<https://devfeed.tech/sources/raymond-hettinger.md>)

Topics: [Open Source](<https://devfeed.tech/topics/open-source.md>), [Learning](<https://devfeed.tech/topics/learning.md>), [open source communities](<https://devfeed.tech/topics/open-source-communities.md>)

Tags: [code](<https://devfeed.tech/tags/code.md>), [contributors](<https://devfeed.tech/tags/contributors.md>), [crowd-sourcing](<https://devfeed.tech/tags/crowd-sourcing.md>), [documentation](<https://devfeed.tech/tags/documentation.md>), [eyeballs](<https://devfeed.tech/tags/eyeballs.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [pip](<https://devfeed.tech/tags/pip.md>), [programmers](<https://devfeed.tech/tags/programmers.md>), [python](<https://devfeed.tech/tags/python.md>), [reading](<https://devfeed.tech/tags/reading.md>), [source-code](<https://devfeed.tech/tags/source-code.md>)

### AI overview

The author argues that developers benefit from reading other projects' source, but large repositories and installers that hide human-readable code make it harder to do. In Python, source once served as a common learning and troubleshooting resource; now, even experienced programmers may rarely inspect code outside their own projects. The author rejects tool mashups as the main obstacle: when documentation fails and the relevant code is known, source inspection can help. The excerpt cites Python 3.2's 216 subdirectories and roughly 876,000 lines across Python and C, and notes that installers place scripts in obscure paths, such as Python's heapq module under a framework library directory. The passage ends while describing where pip installs Mercurial.

### Source excerpt

We all agree, open source is a good thing. It is posited that many eyeballs make all bugs shallow. With crowd sourcing, your users become contributors. And even seasoned programmers benefit from time spent reading code. Further, code can serve as an adjunct to documentation. If you really want to know what software is doing, [...]

## Regaining Lost Knowledge

DevFeed: [Regaining Lost Knowledge](<https://devfeed.tech/articles/regaining-lost-knowledge-21695.md>)

Original publisher: [Read original article](<https://rhettinger.wordpress.com/2010/02/06/lost-knowledge/>)

Author: rhettinger

Published: 2010-02-06T23:28:30Z

Content type: article

Language: en

Sources: [Raymond Hettinger](<https://devfeed.tech/sources/raymond-hettinger.md>)

Topics: [Running Median](<https://devfeed.tech/topics/running-median.md>), [Skiplists](<https://devfeed.tech/topics/skiplists.md>), [Algorithms](<https://devfeed.tech/topics/algorithms.md>)

Tags: [algorithm](<https://devfeed.tech/tags/algorithm.md>), [algorithms](<https://devfeed.tech/tags/algorithms.md>), [data-structures](<https://devfeed.tech/tags/data-structures.md>), [knowledge](<https://devfeed.tech/tags/knowledge.md>), [lost-knowledge](<https://devfeed.tech/tags/lost-knowledge.md>), [median](<https://devfeed.tech/tags/median.md>), [python](<https://devfeed.tech/tags/python.md>), [running-median](<https://devfeed.tech/tags/running-median.md>), [skiplists](<https://devfeed.tech/tags/skiplists.md>), [sliding-window](<https://devfeed.tech/tags/sliding-window.md>), [wikipedia](<https://devfeed.tech/tags/wikipedia.md>)

### AI overview

The excerpt presents an indexable skiplist as a portable O(log n)-time approach to maintaining a running median in a sliding window. Earlier replies based on the median's small movement and a QuickSelect recipe were described as unusably slow for large windows; a published method offered O(√n), while a tree-based solution offered O(log n) but was messy to implement and depended on the blist extension for a ready implementation. Adding link widths to a skiplist made median indexing logarithmic, according to the author, and the resulting approach scales to large windows and is portable across languages. The excerpt claims this application had not previously been presented, while acknowledging the passage is truncated.

### Source excerpt

Rediscovery of Indexable Skiplists in the solution of the Running Median problem.