How can i use python compiler? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How can i use python compiler?

4th Feb 2017, 3:33 PM
lefteris13s
lefteris13s - avatar
9 Answers
+ 3
Python is not a compiled language. However, you can convert .py scripts into .exe using py2exe, cx_freeze or nuitka. Those will, however, build the final application by including Python itself and all the libraries you use in the script. You might end up with a 10+MB file which just prints "Hello world!" ;)
4th Feb 2017, 4:17 PM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 1
Do you mean to transform a .py file into a .exe or to run a python program ?
4th Feb 2017, 3:51 PM
Baptiste E. Prunier
Baptiste E. Prunier - avatar
+ 1
py to exe??? I wasted too much time on that and gave up.
4th Feb 2017, 4:50 PM
seamiki
seamiki - avatar
0
both
4th Feb 2017, 3:51 PM
lefteris13s
lefteris13s - avatar
0
For .py to .exe I do not know but the second part is wrong in itself. Python is an interpreted language so there is no compiler.
4th Feb 2017, 3:52 PM
Baptiste E. Prunier
Baptiste E. Prunier - avatar
0
i cant run python program via the python 2.7?
4th Feb 2017, 3:54 PM
lefteris13s
lefteris13s - avatar
0
you can but they are not compiled
4th Feb 2017, 3:55 PM
Baptiste E. Prunier
Baptiste E. Prunier - avatar
0
How can i use that?
4th Feb 2017, 3:55 PM
lefteris13s
lefteris13s - avatar
0
If you use an IDE, there should be a "run" button (often a green arrow's head) on it, if you do not use an IDE but you are on linux, use the command python (you can find how by yourself if you truly are using linux ;) ). If you have neither an IDE nor linux, I do not know sorry :/
4th Feb 2017, 4:02 PM
Baptiste E. Prunier
Baptiste E. Prunier - avatar