Hacker News new | past | comments | ask | show | jobs | submit login

I agree with the sentiment that, compared to other languages, all else being equal, PHP-the-language sucks; and also agree that all else is not equal, since PHP has a massive installed base, infrastructure support, etc., and that the balance can often tip either way. My first programming job was in PHP, which was used only because of its ubiquity on shared hosting (we even maintained support for PHP 4, when PHP 5.3 was current).

Personally, I don't see much point in arguing the merits of PHP compared to, say, Python, Ruby or Javascript, since those languages are so similar: procedural scripting by default; opt-in use of OO as the happy path for most libraries; functional programming possible, but an uphill struggle WRT APIs, tailcalls, language cruft, etc.

There's also a lot of interbreeding in those language's ecosystems, so there's rarely a killer library/framework/app in one which doesn't have a few carbon copies in the others. I would recommend developers in those languages look at what the others are doing, but I don't see much point in switching between them as an end to itself; go for it when convenient, but nothing much will change (e.g. I was heavily into Python, but fell into PHP dev roles commercially).

The more interesting comparisons are to be made with languages/ecosystems which have a different philosophy, e.g. Java/C#, Haskell/ML, Lisp/Scheme/Lua, C/Go/Rust, C++/D, Smalltalk, Forth, etc. Those kinds of comparison have meat; they're not just bikeshedding about which syntax to write imperative procedural/OO scripts in. I commend the author's choice of learning Go (although I'm not familiar with it myself).

I think the procedural/OO scripting languages will be around for a while to come, but I think their niche is in public-facing applications (usually Web sites, but Python certainly has a heritage of desktop GUIs and CLIs). Certainly the use of REST services is making it easier to use languages for those jobs they're good at; for example, using Go for data crunching, while Web site rendering is done in PHP.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: