Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python

How make python executable without downloading any script.

So I been playing around with python and I would like to share my programs with some friends but they dont want to download python just to use my program .I hear about download c frerze or py2exe but are this script really the only option.

1 Answer

Nathan Tallack
Nathan Tallack
22,164 Points

Python is a "runtime compiled" language. That means your source is compiled as it is run. That's why the Python environment is required in order to run your code.

This has added benefits. It makes it much more portable because you don't need to know anything about the architecture it will be run on as the Python environment on the target platform will compile at runtime. Whereas with precompiled languages you need to know about the target platform when you are making your binaries.

Can I ask what kind of code you are writing that requires the ability to execute on a target system without a Python environment being available? Perhaps I can suggest some alternatives for you if I understand your use case. :)