How to call a function defined in another py file

Martin Blume mblume at socha.net
Mon Feb 19 15:22:56 EST 2007


<silverburgh.meryl at gmail.com> schrieb 
> 
> I have a function called 'test' defined in A.py.
> How can I call that function test in my another file B.py?
> 
In B.py:

import A

A.test()


HTH
Martin





More information about the Python-list mailing list