3 ms·
why not use namedtuples (or plain tuples) instead of dictionaries?
by _ZeD_ 11y ago
why not use namedtuples (or plain tuples) instead of dictionaries?
- dr_zoidberg 11y agoDicts are the fastest dynamic structure out of the box. Tuples will bite you with immutability sooner or later.
- boothead 11y agoI usually think of immutability in terms of saving myself from getting bitten :-)
- dr_zoidberg 11y agoTouché! Thats a nice thought, however string concatenation with the += operator inside a loop is the kind of bite I was thinking about.