Probably I'm just too stupid, but...

Simon Brunning SBrunning at trisystems.co.uk
Wed Apr 24 11:59:37 EDT 2002


> From:	redflag at directbox.com [SMTP:redflag at directbox.com]
> 
	(snip)

> why didn't "c" work as I imagined?
 
Python 2.2 (#28, Dec 21 2001, 12:21:22) [MSC 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> def c():
...     for i in range(10):
...         print i
...
>>> c()
0
1
2
3
4
5
6
7
8
9
>>>

Note the parentheses when calling the function.

Cheers,
Simon Brunning
TriSystems Ltd.
sbrunning at trisystems.co.uk




-----------------------------------------------------------------------
The information in this email is confidential and may be legally privileged.
It is intended solely for the addressee. Access to this email by anyone else
is unauthorised. If you are not the intended recipient, any disclosure,
copying, distribution, or any action taken or omitted to be taken in
reliance on it, is prohibited and may be unlawful. TriSystems Ltd. cannot
accept liability for statements made which are clearly the senders own.





More information about the Python-list mailing list