37 ms·
I think JS in the browser is a great way to start developing these days. The setup is close to zero (a script tag), the dev/build/deploy cycle amounts to saving
by joesmo 11y ago
I think JS in the browser is a great way to start developing these days. The setup is close to zero (a script tag), the dev/build/deploy cycle amounts to saving the file and reloading the browser, and the language itself, while far from perfect, is quite typical of many widely used C-type languages. I'd say this is probably the optimal environment for someone looking to learn programming.
On the server, something like PHP is so ubiquitous, that even though the dev/build/deploy cycle is a little more complicated because it involves a server, it's still a good candidate. With preset stacks like XAMPP/MAMP, all the user has to do is write some code and upload the file to the right place and reload their browser. I think that can be manged. True, the beginner will not know about servers and things like that initially, but that knowledge is not essential or even important to starting out.
I think the big reason for suggesting web development to beginners is interpreters and their ecosystem. Learning an interpreted language is much easier, IMO, for beginners than JIT or AOT compiled languages because the tool chains dev/build/deploy are simpler and many times invisible to the user. Web development does use a lot of interpreted languages. Finally, getting real results on the screen is huge. Showing people they can build real things with only a few lines of code is very powerful and something that is much more powerful in a graphical web environment than on the command line. In web development, the product is graphical by nature, so that is also a huge plus.
- anon1385 11y ago>I think the big reason for suggesting web development to beginners is interpreters and their ecosystem. Learning an interpreted language is much easier, IMO, for beginners than JIT or AOT compiled languages because the tool chains dev/build/deploy are simpler and many times invisible to the user. If you want to do web dev in python then you need a local python environment setup (which is actually trivial on desktop Linux or OS X), and that is no different from somebody using python for local programming. Except their code will be far simpler since they can just read standard input and write to standard output, without having to worry about parsing https requests and constructing valid HTML just so that the results of their basic fizzbuzz code is visible. And they won't need to worry about deploying a server, setting up the domain names, setting up a web server and so on. Setting up a server is also more intimidating because you move into the world of things costing real money and your mistakes being publicly visible. If there's bugs in my small local programs that I write to educate myself then nothing happens the fact majority of the time (rm -rf style bugs can happen of course). If I screw up deploying my server, or do something insecure in php etc, then there are public facing consequences of that (my site gets pwned).