Fwd: is there any principle when writing python function

Yaşar Arabacı yasar11732 at gmail.com
Tue Aug 23 09:20:34 EDT 2011


I accidentally sent below mail only to roy. Resending to groups.

---------- Yönlendirilmiş ileti ----------
Kimden: Yaşar Arabacı <yasar11732 at gmail.com>
Tarih: 23 Ağustos 2011 16:19
Konu: Re: is there any principle when writing python function
Kime: Roy Smith <roy at panix.com>


I don't see myself a good python programmer or anything, but just saying
what I do. I create function for each of the biggest code blocks that is
going to be executed more then once.


2011/8/23 Roy Smith <roy at panix.com>

> In article <j305uo$pmd$1 at solani.org>, Peter Otten <__peter__ at web.de>
> wrote:
>
> > smith jack wrote:
> >
> > > i have heard that function invocation in python is expensive, but make
> > > lots of functions are a good design habit in many other languages, so
> > > is there any principle when writing python function?
> > > for example, how many lines should form a function?
> >
> > Five ;)
>
> Five is right out.
> --
> http://mail.python.org/mailman/listinfo/python-list
>



-- 
http://yasar.serveblog.net/




-- 
http://yasar.serveblog.net/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20110823/41d9c88b/attachment-0001.html>


More information about the Python-list mailing list