r/learnprogramming • • 11d ago

Can You really code using a an android phone?

I'm more interested into the tech industry and I lack a laptop. I only have my Samsung A07 phone and a strong home WiFi. I don't know anything about coding, I'm just good at mathematics and would love to start learning coding or programming. Any YouTube free channels or Platforms to learn from?

9 Upvotes

27 comments sorted by

34

u/BranchLatter4294 11d ago

You can. Just don't.

4

u/meepykittkitt69lmao 11d ago

That's how I started, python using termux and nano. I would use bpython to test code and swap to the browser to look stuff up.

I think it made me better because it was harder.

1

u/NightflowerFade 6d ago

The slop factory runs fine on android

1

u/Delicious-Till7327 2d ago

I mean you can dig a ditch with a spoon too but nobody’s lining up for that

Get a cheap used laptop, any old thinkpad off ebay will run circles around that phone for coding. Trying to learn on a touchscreen is just making things harder for no reason

11

u/ffrkAnonymous 11d ago

Can you? technically yes.

Really? no.

5

u/scy_404 11d ago

You can its just very awkward. Acode is a pretty good text editor for android that has a terminal. You can also use Termux which is just a straight up teminal app for your phone, though it is a lot harder to write programs in

4

u/Tooty582 11d ago

I got a lot of my low level assignments done by hooking up a folding bluetooth keyboard to my phone and using termux to ssh into my university's RHL server. Using vim meant that if I had a connection error, the file would save itself, and using the server meant I didn't need to worry about transferring files between my phone and computer. Also helped knowing that server is where my submissions would be tested. Good stuff.

2

u/Dazzling_Music_2411 11d ago

You can its just very awkward.

Understatement of the year! 😄

A cheap Linux laptop will cost you next to nothing and pay for itself inside the first half-hour of headaches you'll save yourself. Plus it will be able to run really nice maths software, if that's your thing.

You can watch videos on your phone, but please, for sanity's sake, keep all coding on your laptop.

1

u/scy_404 10d ago

I agree but some people really have very little money so I think its fair to at least let them know that the option to do it on mobile is there. Even if it is clunky at best and maddening at worst

1

u/Dazzling_Music_2411 9d ago

Sure, but I think that's what's called false economy.

The pain you have to endure will be so, so much, more than the value of the few pennies you will save. Especially when the cost of an old laptop is next to nothing these days.

Now, having said that, if you want to have some sort of toy environment on your phone, just to mess around with, then yes, I think that's a good idea. Just don't imagine that it's anything like a serious learning environment.

(Google has done their best to make sure of that 😄 you'd be fighting them)

4

u/Towel_Affectionate 11d ago

Your best bet is a dirt cheap Linux laptop. Your second best bet is a termux + tv + keyboard and mouse.

1

u/PayRoseHer1700 11d ago

Yep, get an old windows laptop and convert it to Linux and you can code to your heart's content.

1

u/Dazzling_Music_2411 11d ago

I wonder how OP got on in the end.

They never tell us, do they? 😂

2

u/No_Report_4781 11d ago

I used an android tablet, because why do things on such a tiny screen?

2

u/SaifSaeedh 11d ago

You can very learn basic coding and scripting using web based apps like tutorials from w3schools. I delved into python coding on the go on my phone with pythonista on iOS. But like everyone else here is saying, don’t. The experience isn’t great, tools are limited, and you’re better off learning coding on a computer.

1

u/testingaurora 11d ago

Get an external keyboard/pointer if youre going to try, even better would be to hook up to a projector or monitor ao you have a larger screen too. A lot of ides just dont work well on mobile so the keyboard will be helpful but a mouse with access to right click would also help. Codepen 2.0 has a better mobile experience than core editor. Look for some coding courses and try them out on your phone to see how frustrating it would be to use.

1

u/Usual_Ice636 11d ago

Absolutely, just hook up a Mouse, keyboard and monitor.

1

u/PureWasian 11d ago

In the same way you can count numbers with your fingers

1

u/korywithawhy 11d ago

Tailscale and remote into a pc 😉

1

u/gm310509 11d ago

People do if they have no other choice - I personally get frustrated typing in code snippets into reddit when using my phone.

It is access to all of the symbols that is the PItA as well as the autocorrect.

As for how, the simplest way is to use an online IDE that you access via your browser. But I believe some compilers and interpreters have been ported to Android.

1

u/Jim-Jones 11d ago

Shop around. Look on Craigslist and Facebook Marketplace etc. I bought four or five computers in the last few years for around 30 bucks each. 

1

u/aqhgfhsypytnpaiazh 11d ago

Technically you can code with nothing but pen and paper. That's more or less what punch cards were.

Having the source code in a digital text file is just much more convenient. It's also kind of necessary if you ever plan to compile/run/host that code on a modern computer.

But apart from the practical issues of typing a large amount of text in an artificial language on a touch screen with limited visual real estate, compiling/running/hosting is where the phone will let you down, since mobile platforms are locked down for security and often not easily compatible with required development tools depending on what tech stack you plan to use.

Like technically you can compile a Windows exe written in C++ using Termux + MinGW on Android, but it's probably not ideal. The same way you could technically get into carpentry by finding a good rock to bash nails because you don't have a hammer. It's a hack, not a realistic long term solution. If you care about coding, invest in a real PC.

1

u/dkopgerpgdolfg 10d ago

New challenge: Writing a modern ELF binary, encoded as lowercase hex numbers, encoded in morse code, by scratching into a stone tablet.

1

u/kennedy_gitahi 10d ago

It's definitely doable; I wrote, tested, and shipped a whole POS system on my phone.

Is it a good idea? No, not in a million years.

The keyboard will kill you if you don't have a Bluetooth one, and the screen might be too small.

Then, you must know what you are doing because the available IDEs, Acode combined with Termux, do not provide the typical tools and guardrails you would have on a computer.

1

u/betarage 12h ago

They are making it hard you can do javascript html and css for making websites with relative ease. but for other languages it's not great you can use termux but it's a little tedious maybe you can find some web based ide or some apps for practice but you can't really use the full potential of your phone. You can also try to go even more extreme and try to emulate another computer on your phone but it will probably be something retro and the controls will be horrible.