|Code Listing by runsun pan|
Group a list of items according to the starting character(s) of items.
This is based on Raymond Hettinger's groupby class:
Python style switches. Showing several ways of making a 'switch' in python.
A collection of some dictionary tools
<code>A dict extension that has the following features:
1. dual data storages: use 'bd.x' or 'bd["x"]' for one,
and bd.getDict() for another.
2. All the followings are equivalent::
This recipe provides an alternative way of generating and updating dictionaries. It savs couple of keystrokes, making routine dict operations easier.
Sometimes we want to have a module initialized in different ways. This function, getimporter(), while placed inside a module X, allow you to initialize module X according to the module (properties) that is importing X.
Presented in this recipe is a function prop, with that a property myprop can be created as simple as:
def myprop(): pass
It has only 7 lines of code, easy to understand, easy to customize, will make the code...
A collection of some useful list-related functions.
All files and free downloads are copyright of their respective owners. We do not provide any hacked, cracked, illegal, pirated version of scripts, codes, components downloads. All files are downloaded from the publishers website, our file servers or download mirrors. Always Virus check files downloaded from the web specially zip, rar, exe, trial, full versions etc. Download links from rapidshare, depositfiles, megaupload etc not published.