praba kar wrote:
> Dear All,
> 
>      I want to know about Modules and packages.
> I can understand about Modules but I cannot understand
> about Packages.  Kindly let me
> know about Packages with small example.
> I can understand conceptually but I don't know
> how to write programmatically.
> 
> regards
> Prabahar
> 
Prabahar:

In your headers I see "In-Reply-To: 
<[EMAIL PROTECTED]>". This means 
that people will see your message as part of another thread. It's better 
not to do that if you want your message to be read in the proper context.

A package is simply a directory containing an __init__.py file, which is 
executed when the package is imported. Sub-packages are subdirectories 
of the package main directory containing __init__.py files, which will 
be executed when the sub-package is imported. Packages can also contains 
modules, which are regular Python files that are executed when the 
module is imported.

So, in brief, packages are just a way to let you organize your code in 
to a set of mutually dependent modules and sub-packages, making source 
maintenance easier and allowing selective import of parts of the 
implemented functionality.

regards
  Steve
-- 
Steve Holden       +44 150 684 7255  +1 800 494 3119
Holden Web LLC             http://www.holdenweb.com/

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to