At the beginning of script2.py, write:
>From script1 import , ...,
Sincerely,
Geneviève
_
De : [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] De la part de Robert
Berman
Envoyé : vendredi 14 novembre 2008 13:57
À : [tutor python]
Objet : [Tutor] referencing external functions
bob gailer wrote:
A.T.Hofkamp
wrote:
(I would suggest to use more meaningful names
than scriptX.py)
Perhaps Robert uses (as I do) Python for Windows. "Save" proposes
script1, script2, ... as the initial filename.
WIBNI it could cleverly guess a meaningful name as
On Fri, Nov 14, 2008 at 7:56 AM, Robert Berman <[EMAIL PROTECTED]> wrote:
> I have a number of functions written in a python script called script1.py.
> In another script, script2.py, I need to use a number of the functions
> residing in script1.py. How do I make these functions known to script2.p
A.T.Hofkamp wrote:
Robert Berman wrote:
I have a number of functions written in a python script called
script1.py. In another script, script2.py, I need to use a number of
the functions residing in script1.py. How do I make these functions
known to script2.py.
Thank you,
script1.py:
def
Robert Berman wrote:
I have a number of functions written in a python script called script1.py. In
another script, script2.py, I need to use a number of the functions residing in
script1.py. How do I make these functions known to script2.py.
Thank you,
script1.py:
def f(n):
return n + 1
I have a number of functions written in a python script
called script1.py. In another script, script2.py, I need to use a
number of the functions residing in script1.py. How do I make these
functions known to script2.py.
Thank you,
Robert
___
Tu