[Tutor] question 1
Danny Yoo
dyoo at hashcollision.org
Sun Sep 21 03:41:50 CEST 2014
>> Secondarily, why can you import a module without it importing all of its
>> daughters?
>
> The act of importing a module is "recursive": if you import a module,
> and that module itself has import statements, then Python will do the
> import of the child modules too. And so forth.
Hi Deb,
Oh! By the way, this echoes that point about recursion from a week or so ago.
https://mail.python.org/pipermail/tutor/2014-September/102715.html
So yes, recursion shows up at the heart of the Python module import
system too. That should have been an obvious example, but I forgot.
:P
More information about the Tutor
mailing list