How to run python3 on android like you run on an terminal? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

How to run python3 on android like you run on an terminal?

Actually, I already have a solution for this. My solution : installing Qpython on android then installing an terminal emulator and calling intialization script of Qpython and pass first argument as program file in it. I actually want better solution than this cause every time I do this I have to specify full path for both like root@kanas:/ # /data/data/org.qpython.qpy3/files/bin/s/bin/qpython.sh /sdcard/qpython3/try.py well I can create symlink to call initialization script to make it something Ez Pz

29th Apr 2018, 4:35 PM
Yugabdh
Yugabdh - avatar
8 Answers
+ 1
QPython has a plugin (avaible on market) with python3 support (though dont work to me)... More there is another python 3 interpreter PyDroid
29th Apr 2018, 6:21 PM
KrOW
KrOW - avatar
+ 4
Try getting Termux and running "pkg install python" to install it.
29th Apr 2018, 4:54 PM
LunarCoffee
LunarCoffee - avatar
+ 3
Hm... maybe just hardcode them in for now, but remove them after testing: def main(argv=["a", 5]): # stuff
29th Apr 2018, 5:23 PM
LunarCoffee
LunarCoffee - avatar
+ 1
my android don't support termux :(
29th Apr 2018, 5:05 PM
Yugabdh
Yugabdh - avatar
+ 1
Can you elaborate please. like you mean I should pass values to main function directly rather than passing them on runtime. If you mean this I don't want to do that, I want to use switches to pass values at runtime only.
29th Apr 2018, 5:57 PM
Yugabdh
Yugabdh - avatar
0
So what I need is better solution than what I have already. I didn't find any perfect solution online most of them are for running python in console
29th Apr 2018, 4:39 PM
Yugabdh
Yugabdh - avatar
0
I need this to to pass commandline arguments like program I have here https://code.sololearn.com/cO56oW85se2J/?ref=app
29th Apr 2018, 4:40 PM
Yugabdh
Yugabdh - avatar
0
Well with Pydroid I can call python directly in its terminal. Thanks. I also have another idea for my previous setup I created shell having address of Qpython.sh and named it py and moved it to /bin of terminal now I can call python by typing just py in terminal
30th Apr 2018, 6:25 AM
Yugabdh
Yugabdh - avatar