all the above languages have ... superior performance to scripting languages.
If you have one (and I'm sure that if anyone has it will be you :-) I would be interested to see a reference for this as it pertains to Java. My experience has been quite the opposite.
| [reply] |
hippo you've caught me unprepared! ... so I can feel a future meditation brewing on this complex and interesting topic. :)
Static typing usually results in compiled code that executes faster.
When the compiler knows the exact data types that are in use (which is necessary for static verification, either through declaration or inference)
it can produce optimized machine code.
Some dynamically-typed languages such as Common Lisp allow optional type declarations for optimization for this reason.
-- from Type system (wikipedia)
As indicated by the quote above, my performance assumption of the five listed (statically typed) languages (including Java) was based solely on the
well-known general properties of static vs dynamic typing.
When I programmed in Java years ago, I remember the HotSpot technology muddying the performance waters
when attempting to compare Java to C++ because (at least in theory) Java HotSpot could perform gradual dynamic
performance optimizations at run-time (based on HotSpot profiling and the specific hardware it was running on)
which C++ could not (update: nowadays it can, thanks to Chris Lattner's LLVM and Clang).
Despite that, I've always loved C++ and disliked Java, and would always back C++ against Java in any specific benchmark shootout. :)
References Added Later
- Type system (wikipedia) - Languages are often colloquially referred to as strongly typed or weakly typed. In fact, there is no universally accepted definition of what these terms mean.
- Strong and weak typing (wikipedia)
| [reply] |
I'll stick by my recommendation of javascript, because the last thing a kid would want to do is have to write their program twice so that their iPhone friends and android friends can both see it. And don't forget the hassle of tooling and publishing on the app store.
I recently came across an IRC client called The Lounge which is the single best written JavaScript GUI I've ever used. I haven't had time to pick apart the source code yet, but they built that thing with the best that web technologies have to offer. You can browse to it from any common web browser, and on mobile devices there is a button in the UI to save a link to it onto the phone's desktop as if it were a native app. It's indistinguishable from a native app and functions better than half the apps on my phone. And best of all, it's free and allows me to cross off my TODO list item for that web-based multi-platform IRC bouncer I always intended to write, and without regrets, because this is way better than what I would have created.
| [reply] |
And don't forget the hassle of tooling and publishing on the app store
Ha ha, not to mention the cost. Every hobbyist Apple developer I met at work actually lost money!
Admittedly, they were Apple die-hard fans and novice iPhone developers with a full-time day job ... but the
annual Apple Developer Program fee turned out to be greater than what they earned from their App! :)
| [reply] |