[prev in list] [next in list] [prev in thread] [next in thread] 

List:       python-list
Subject:    Re: WANT: bad code in python (for refactoring example)
From:       Irmen de Jong <irmen.NOSPAM () xs4all ! nl>
Date:       2017-02-14 23:12:54
Message-ID: 58a38ef5$0$673$e4fe514c () news ! xs4all ! nl
[Download RAW message or body]

On 14-2-2017 23:44, Makoto Kuwata wrote:
> Hi,
> 
> Is there any *just right* python code to refactor?
> In other words, I'm finding bad code example in python.
> 
> (background)
> I'm teaching Python to some novice programmer, and
> want to show refactoring example to them.
> 
> (required)
> * not good code
> * not too large (for novice programmer)
> * not too complex (for novice programmer)
> * released under open source license
> 
> If you know good material in github or bitbucket to refactor,
> let me know it.
> 
> --
> regards,
> kwatch
> 


No code in text form, but I find the following video by Raymond Hettinger very clear
about the values of refactoring otherwise seemingly fine code

https://youtu.be/wf-BqAjZb8M?t=12m39s

code starts at 12 min. 40 sec.

It does require a bit of background knowledge about Python and the PEP8 code style and
API design.

Irmen

-- 
https://mail.python.org/mailman/listinfo/python-list
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic