DEV Community

Choosing a programming language for bloody Beginners

hepisec on August 08, 2018

This post is a sequel to my post 'Programming for bloody Beginners' and will give you an overview on types of programming languages, their purposes...
Collapse
 
alldanielscott profile image
Daniel Scott

I'm curious as to why PHP is your preferred choice for web applications. I've used it a lot, and I gravitate towards it whenever I'm developing on a LAMP stack or building on a CMS like Wordpress or Drupal, since it's well supported and well understood, but - frankly - it's an awful language full of bizarre behaviours that cause huge amounts of frustration.

I see that all the cool kids are starting to jump on the node.js bandwagon. Drupal is dying (and rightly so). Wordpress is thriving, but there are noises being made about whether it'll some-day be possible to move away from PHP (not anytime soon I suspect).

Personally, I've always thought server-side JavaScript made an awful lot of sense (learn one language and you can code on both sides of the browser). Plus, other than the whole having-to-deal-with-floating-point-numbers-everywhere dilemma, JavaScript is really quite a lovely language.

Netscape used to push server-side JS decades ago (but hardly anyone used their web server), and Microsoft had their own "JScript" implementation back in the classic ASP days but tended to push VBScript far more heavily because ASP developers tended to be VBA developers who'd been tasked with "building a website".

Node.js seems to be the "third-time lucky" for server-side JS and I'd be inclined to take a good-hard look myself.

Currently, if I'm building something bespoke, I'll tend to gravitate towards ASP.Net MVC - because it's lovely. This seems to be creeping into the open source space now that Micro$oft are doing some good work with the whole ASP.Net Core thing. Working in C# (a high-level compiled language) is sooooo much more productive for me than horrible PHP. All the dumb mistakes you might make get caught early in the coding process, leaving far fewer issues to track down and fix at runtime. I've had some very choice monosyllabic words for PHP (and it's designers) leading up to project deadlines before (while tracking down bugs that never should have been able to happen).

I tend to use PHPStorm when I write PHP, and it tries its best to work like an IDE for a compiled language, but all the idiotic things that PHP does (and encourages developers and designers of PHP frameworks to do) tend to hobble its efforts. True, server-side JS will share a few of those issues, but at least the language wasn't designed by the brrrrp who designed PHP.

Collapse
 
hepisec profile image
hepisec

I agree that PHP has its flaws, but if you work with a framework like Symfony, you get an awesome toolset to quickly develop enterprise grade web apps. What I noticed from my students is that they need to understand the difference between server side and client side code. When they switch languages from PHP for server side to JS for client side, this difference becomes more clear.

In my own case, I also use PHP because it fits in our company environment.

Collapse
 
lewiscowles1986 profile image
Lewis Cowles

A Little detail-oriented for a new programmer. Perhaps after they have their first program they can focus on typing, compilation etc.

Collapse
 
hepisec profile image
hepisec

Do you think that the post is to hard to understand or are there just too much details in it?

Collapse
 
theminshew profile image
Michael Minshew

I think it was useful, Not sure that a pure total beginner would get it all but its both introductory and a reference and at leasts points to things you'll want to look up down the road. Love this type of stuff!

Collapse
 
vitalcog profile image
Chad Windham

Kinda depends on the individual beginner. In my early days as a complete noob (right now I'm upgraded to only being a partial noob...) I would have loved that article. Because it is full of really useful terms and any of the stuff I didn't understand I would look up ASAP. But I definitely could see a lot of complete beginners being overwhelmed with the depth of details if they haven't even written "hello world" yet...

Collapse
 
lewiscowles1986 profile image
Lewis Cowles

I understand it, but as someone that helps businesses with people that are new to subjects I thought it was a bit too much at once for beginners that have never coded and don't know where to start.

Perhaps interspersing examples would break it up a bit more? Perhaps less things people can worry about later, such as compiling vs interpreted (IMO everyone should start interpreted because they then don't need to learn about compiler flags, and build-systems nuance).