some beginners questions about programming

Dave Angel d at davea.name
Sat Apr 21 07:29:08 EDT 2012


On 04/21/2012 06:03 AM, Santosh Kumar wrote:
> Hello Python Developers,
>
> I have a very less experience with programming. I have digged a little bit
> of all (I mean *C, **Java, JavaScript, PHP*) at introductory level and now
> I have two question about it.
>
>    1. Are *Arrays* and *Lists* same things?
>    2. Are *Modules* and *Libraries* same things?
>
>
No
No

None of those words is well defined without choosing a language first. 
What Python uses for the built-in type 'list' is closest to what C++
call s a vector.  What C++ usually calls a list doesn't exist in Python.

In Python, a module is the code in one importable file, a package is a
group of such files defined by their directory relationship to each
other, while a library is a word used loosely to describe a collection
of such files.  Other languages use the word to describe possibly very
different things.   For example, in C, a module is the amount of code
that the compiler handles at one time.  Modules are then combined
together using a linker to form either an executable or a library.  And
a library may be of at least two different types, statically linked to
the executable, or dynamically loaded at run time.

And some of those terms vary from OS to OS, as well as from language to
language.



-- 

DaveA




More information about the Python-list mailing list