In article <17gt99hg615jfm7bdid26185884d2pf...@4ax.com>, Tim Roberts <t...@probo.com> wrote:
> Piotr Dobrogost <p...@google-groups-2013.dobrogost.net> wrote: > > > >Attribute access syntax being very concise is very often preferred > >to dict's interface. > > It is not "very concise". It is slightly more concise. > > x = obj.value1 > x = dct['value1'] > > You have saved 3 keystrokes. That is not a significant enough savings to > create new syntax. Remember the Python philosophy that there ought to be > one way to do it. I'll trade typing [ ' ' ] for . any day. Easier to type, easier to read. It's not just the character count, it's that you need to move your fingers off the home row (or, at the very least, a big stretch with your pinkie) to reach the brackets. I suppose that depends on your particular keyboard layout and typing style/skill. -- https://mail.python.org/mailman/listinfo/python-list