Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #51552
| From | Neil Cerutti <neilc@norwich.edu> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: import syntax |
| Date | 2013-07-30 13:03 +0000 |
| Organization | Norwich University |
| Message-ID | <b5prt4F240sU1@mid.individual.net> (permalink) |
| References | <51F6C720.2020404@Gmail.com> <kt6i57$2ku$1@ger.gmane.org> <20130729152051.46003bcf@bigbox.christie.dr> <51F6CF36.7080702@Gmail.com> <mailman.5281.1375137506.3114.python-list@python.org> |
On 2013-07-29, Joshua Landau <joshua@landau.ws> wrote: > Sure, just as one light is no brighter or dimmer than another > when disregarding luminosity. > > As people have said, it improves diffs as well. It flows > quicker into the "from module import things" form (which I oft > prefer), too. > > When asking these questions, ask yourself "why would it > *compile* differently? It wouldn't. Plus, premature > optimisation is the root of all evil. > > 1) Write your code > 2) If it's slow: > 2a) Do you have time? If so: > 2b) Is it important to speed up, or is the slowness not worth spending the > hours fixing? > 2c) Profile it to see what's actually slow > 2d) Realise that the slow part is not what you thought it was > 2e) Fix the bit that's slow (and nothing else) > 2f) Repeat from 2 > 3) Write some more code 1a) Does it work? 1b) Can you prove it? It's best to at least have some regression tests before you start refactoring and optimizing. -- Neil Cerutti
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: import syntax Joshua Landau <joshua@landau.ws> - 2013-07-29 23:37 +0100 Re: import syntax Neil Cerutti <neilc@norwich.edu> - 2013-07-30 13:03 +0000
csiph-web