Attribute getters in python
<p>I vaguely remember learning about some sort of built-in function that would do the equivalent of</p>

<pre><code>f = lambda x: x.attr
</code></pre>

<p>Am I just imagining this or does such a thing exist? </p>
