More about simple question

Brad Hards bhards at bigpond.net.au
Tue Nov 5 16:02:31 EST 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wed, 6 Nov 2002 05:09, xinghua shi wrote:
> Hey,thanks you all. Actually, I messed up the
> indentation and I first thought it's not a big problem
> as I used to write in C.
I'm just changing over from C myself. Python is definately not the same 
language, and you should _not_ think of it as "C with a different syntax"

> I still have another question. If I have a file named:
> foo.py. then how can I get an excetable, say foo?
> In C, I could use
> % gcc foo.c -o foo
>
> So how can I do similar in Python?
> %python foo.py -o foo
> doesn't work of course.
Python isn't compiled, and you probably shouldn't be looking for an answer 
that involved a compiler.

Typically, you'd make a script:
http://www.python.org/doc/current/tut/node4.html#SECTION004220000000000000000
I'm not sure how well this will work in Windows though.

There are other alternatives (py2exe is one that I've seen, but not played 
with)
http://starship.python.net/crew/theller/py2exe/
- -- 
http://linux.conf.au. 22-25Jan2003. Perth, Aust. I'm registered. Are you?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9yDHnW6pHgIdAuOMRAtVQAJ9WU2IbqjAv748eCSwWWBVCcDFIrQCfWxqg
HePyjZMJzgE2jNXDAarrJ6I=
=+g1q
-----END PGP SIGNATURE-----





More information about the Python-list mailing list