Can anyone help me to use termux in my phone for compiler c c++ programs | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 10

Can anyone help me to use termux in my phone for compiler c c++ programs

I found in that you can code in phone using termux .But I don't know can anyone suggest me a tuturiol sorry for bad English

7th Mar 2017, 4:19 PM
Mrityunjay Jha
Mrityunjay Jha - avatar
9 Answers
+ 28
open termux : 1) install c++ compiler: apt install clang 2) install an editor. for example nano: apt install nano 3) create new .cpp file with editor: nano filename.cpp 4) write your c++ program. to save file press (ctrl+x) or [volume down + x] then y and enter 5) compile: clang++ filename.cpp -o filename 6) run : ./filename sorry for bad English.
16th Mar 2017, 10:30 AM
Arman Donic
Arman Donic - avatar
+ 8
termux is powerfull! not only for c++, ruby, python.... thank you very much!!
18th May 2017, 6:56 PM
Emore Anzolin
Emore Anzolin - avatar
+ 4
Thnx
16th Mar 2017, 12:41 PM
Mrityunjay Jha
Mrityunjay Jha - avatar
+ 3
you use also vim aditor for writing program and u can install with command pkg install vim
24th Apr 2018, 5:38 PM
Savan Patel
Savan  Patel - avatar
0
u can also use "gcc" command to compayl program run : pkg install c++
25th Apr 2018, 3:04 AM
Savan Patel
Savan  Patel - avatar
0
And micro too
22nd Feb 2019, 2:36 PM
Hoang Phantom
0
How to run java...
3rd Apr 2019, 2:11 AM
jony
jony - avatar
0
You can't run Java natally in Termux, you need to emulate a Linux Dist. (Use AnLinux, works with Termux)
3rd Apr 2019, 2:15 AM
The Bloodbath Alchemist
The Bloodbath Alchemist - avatar
0
Savan Patel I recomment nano over vim And its not pkg install c++ its pkg install clang
1st Oct 2020, 6:29 AM
Gyan Prakash Singh Jaruhar
Gyan Prakash Singh Jaruhar - avatar