Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #43502
| Newsgroups | comp.lang.python |
|---|---|
| Date | 2013-04-12 22:25 -0700 |
| References | <mailman.429.1365635789.3114.python-list@python.org> <51678b94$0$29977$c3e8da3$5496439d@news.astraweb.com> <roy-E3B2B9.10194712042013@news.panix.com> <mailman.527.1365781666.3114.python-list@python.org> |
| Message-ID | <f22e42d0-1ac7-412f-b1a7-e8325288fdaf@googlegroups.com> (permalink) |
| Subject | Re: Functional vs. Object oriented API |
| From | 88888 Dihedral <dihedral88888@googlemail.com> |
David M Chess於 2013年4月12日星期五UTC+8下午11時37分28秒寫道: > > Roy Smith <r...@panix.com> > > > > > > As part of our initial interview screen, we give > applicants some small > > > coding problems to do. One of the things we see a lot is what > you could > > > call "Java code smell". This is our clue that the > person is really a > > > Java hacker at heart who just dabbles in Python but isn't really fluent. > > > > ... > > > It's not just LongVerboseFunctionNamesInCamelCase(). Nor is > it code > > > that looks like somebody bought the Gang of Four patterns book and > is > > > that maybe there's a class struggling to be written. > > > > And I think equally to the point, even if you have > only data, or only functions, right now, if the thing in question has that > thing-like feel to it :) you will probably find yourself with both before > you're done, so you might as well make it a class now... > > > > DC If it is not time-critical and no needs to convert into CYTHON then it does not matter too much. But a well wrapped class structures with good documents can help others to use the python codes a lot. If the part is intended to be time-critical in the low level part, then avoiding seeking 4 levels of methods and properties inside a loop is helpful in python programs to be executed in the run time.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Functional vs. Object oriented API Max Bucknell <mpwb500@york.ac.uk> - 2013-04-11 00:16 +0100
Re: Functional vs. Object oriented API Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-04-12 04:20 +0000
Re: Functional vs. Object oriented API Roy Smith <roy@panix.com> - 2013-04-12 10:19 -0400
Re: Functional vs. Object oriented API Mitya Sirenef <msirenef@lightbird.net> - 2013-04-12 10:29 -0400
Re: Functional vs. Object oriented API David M Chess <chess@us.ibm.com> - 2013-04-12 11:37 -0400
Re: Functional vs. Object oriented API 88888 Dihedral <dihedral88888@googlemail.com> - 2013-04-12 22:25 -0700
Re: Functional vs. Object oriented API 88888 Dihedral <dihedral88888@googlemail.com> - 2013-04-12 22:25 -0700
Re: Functional vs. Object oriented API Rui Maciel <rui.maciel@gmail.com> - 2013-04-13 09:51 +0100
csiph-web