On Mon, Sep 14, 2009 at 4:29 AM, Sean DiZazzo wrote:
> Is this a production program that you are using??
>
> Please show us the point you are trying to make in something more
> valuable.
I find this a very bad comment. Not only is it rude, it is condemning
a behaviour I would see as beneficial.
python
>
> if __main__ == '__main__' :
> print "Hello World!\n"
> $ ./test.py
> Traceback (most recent call last):
> File "./test.py", line 3, in
> if __main__ == '__main__' :
> NameError: name '__main__' is not defined
You ar
__ == '__main__' :
> print "Hello World!\n"
> $ ./test.py
> Traceback (most recent call last):
> File "./test.py", line 3, in
> if __main__ == '__main__' :
> NameError: name '__main__' is not defined
erI was jus
__ == '__main__' :
> print "Hello World!\n"
> $ ./test.py
> Traceback (most recent call last):
> File "./test.py", line 3, in
> if __main__ == '__main__' :
> NameError: name '__main__' is not defined
Is this a produc
__ == '__main__' :
> print "Hello World!\n"
> $ ./test.py
> Traceback (most recent call last):
> File "./test.py", line 3, in
> if __main__ == '__main__' :
> NameError: name '__main__' is not defined
You wrote __main__
g
>
> $ cat test.py
> #!/usr/bin/env python
>
> if __main__ == '__main__' :
> print "Hello World!\n"
> $ ./test.py
> Traceback (most recent call last):
> File "./test.py", line 3, in
>if __main__ == '__main__' :
> Na
recent call last):
File "./test.py", line 3, in
if __main__ == '__main__' :
NameError: name '__main__' is not defined
--
http://mail.python.org/mailman/listinfo/python-list