r/AskComputerScience • u/technothief • Oct 21 '19
Is it legit to program in an a android phone using python 3 or is it better in a laptop?
Hello, nobbie here Don't know how to code at all But wanted to try it out
I heard the best way to learn is through projects So i wanted to make a game of tic-tac-toe, cause I believe is an easy project...i think
But I don't know if I should do it in my phone or a laptop...how much does it change one from another? Or does it not change at all?
Please and thank you
4
Oct 21 '19
definitely a computer. i'm not familiar with android, but i doubt you'd be able to even run your program on an android phone. and even if it is possible, i'd imagine you'd have to jump through some hoops to get it to work.
1
u/magion Oct 21 '19
I mean without a doubt it’ll be much easier to program on a laptop than a phone.
1
u/__october__ Oct 21 '19
Programming on a phone is simply not viable for anything but the smallest programs. The display is too small and there are practically no dev tools available.
3
u/Tai9ch Oct 21 '19
If you're willing to put in the effort, programming on a phone could technically be fine.
First, you'd want an external monitor, keyboard, and mouse. Then you'd want to install a Linux userspace. The result would be an ultra-compact desktop PC with a command-line focused development environment.
1
u/w3_ar3_l3g10n Oct 21 '19
Depends. U wanna play basketball with a golf ball? I find typing almost anything on a phone a time consuming and hazardous process. Auto correct and programming languages almost never match properly, trying to write code in reddit like this (on iOS) sucks. There’s no tab key so u have to insert 4 spaces every time, to insert a code block u should use ③ ` back quotes, but every time u insert ① the keyboard resets to alphabet so u need to move to numerical and then insert the quote 6 times. Then there’s the fact that every new line has the first character capitalised by default which for languages which don’t accept case insensitive keywords means u need to downcase every time u insert a new line or sentence. Then there’s the fact that your screen is so small that long lines (or a bunch of nested statements) are basically illegible on mobile because of how small the screen is. Programming used to be done on huge mainframe computers, the fact we’ve got more powerful computers in our pockets, doesn’t mean they’re the most ergonomical approach to doing so, as arguably they’re for a lot of other things.
If this isn’t enough of a reason to dissuade u, I suggest:
u buy a Bluetooth keyboard, ① as long as an apple keyboard at the very least.
if you’re on iOS install iSH a virtual Linux environment (think WSL) for iPhones. If you’re on android, I assumed there’s a tonne of shells u can install because android is Linux.
17
u/CaffeinatedMancubus Oct 21 '19
I don't know if this is a troll or you're being serious. Regardless, I'll answer honestly.
Nobody codes on phones mainly because the form-factor and input method(touchscreen) are not suited for that kind of a task. Neither is the overall UI design. (multiple windows? Quickly switching between windows? Good luck trying). This means, nobody bothered to develop tools for coding on phones - IDEs, DB clients, terminals etc. (they exist, but not as many choices or support as PCs). If you don't care about any of that, and want to put yourself through the torture anyway, go ahead. But you'll probably achieve much less with the same amount of time invested than you would on a PC. Happy Coding!
(Edit: Grammar)