We're starting to develop greenfield APIs in Scala (with Play) rather than PHP (with Laravel) and we've noticed new developers without experience in either language have a surprisingly similar time-to-productivity. Here are some major factors: PHP's dynamic typing combined with Laravel's magical approach makes discoverability hard. A developer can't trace through a request by starting from a controller method and nav…
Thanks for posting that. Where would a PHP programmer go to get a foothold in Scala web development?
Ask HN: When has switching the language/framework made an important difference?
61–70 of 152 posts
Re: Ask HN: When has switching the language/framework made an important difference?
#62Earlier quoted context omitted.
I’ll say it again. If the natural language of your problem domain is linear algebra and/or matrices (tensors), Fortran is the perfect tool.
Why is it better than C(++) for this?
I am not sure if this performance advantage is still the case as the wikipedia page on pointer aliasing notes that C99 added a "restrict" keyword so that the C programmer can tell the C compiler where similar strong assumptions can hold.
Re: Ask HN: When has switching the language/framework made an important difference?
#63After a few months slogging through an unfamiliar language, the company decided to switch to java. Productivity went up, surprise!
Re: Ask HN: When has switching the language/framework made an important difference?
#64A few years ago, I rewrote an `R` script into Fortran, for better than order-of-magnitude speed increase. The script optimized the placement of samplers in a building, in order to maximize the probability of detecting airborne pollutants, or to minimize the expected time required to detect. The rewrite cut the runtime down from 2-3 days to sub-hour. Some of the speedup was intrinsic to the interpreted/compiled divide…
This is the first time that I have ever encountered someone who used Fortran for something other than earth sciences related modeling. Thank you, now I have a second example the nest time someone claims "nobody used fortran anymore".
similarly, the backend of the original "random forest" machine learning algorithm for R was written in fortran, and then wrapped as an R library, but as an R user you could largely pretend that fortran didnt exist. R was a pitifully slow language so this was a good move.
Re: Ask HN: When has switching the language/framework made an important difference?
#65Unfortunately Ernie didn't work as well as it advertised, had many edge cases, and in the end it was a big bottleneck (it would have been faster to ditch Erlang and use plain Ruby).
In the end we wrote everything in Erlang. It wasn't that hard in the end, and the reason why we went down the Ruby route in the first place was because the platform was over-engineered to be as generic as possible (which wasn't needed), so we didn't actually lose anything.
Re: Ask HN: When has switching the language/framework made an important difference?
#66Moving a large C++ codebase to C# has helped us a lot. The legacy code had memory leaks that caused random crashes. It was also long to build, and wouldn't build in 64 bit. The C# version seemlessly let us run the code in either 32 or 64 bit. C# is also a much more readable language, and has a lot of great tools for refactoring and profiling. And C#'s performance is almost as good as C++ in many areas, so all in all…
Re: Ask HN: When has switching the language/framework made an important difference?
#67I am an amateur developer, mostly using python. I had from time to time to code a front-end in JS and it was a huge pain in the bottom (again, I am a real amateur). This until I discovered Vue.js which changed my life. This and lodash made me actually like JS and front-end programming. So this is an example what a framework did not help to improve code but actually made me choose in something else than the language I…
Currently using it in a ColdFusion project to retrofit a modern frontend to oldish code. Works like a charm, without a full rewrite.
Re: Ask HN: When has switching the language/framework made an important difference?
#68I am an amateur developer, mostly using python. I had from time to time to code a front-end in JS and it was a huge pain in the bottom (again, I am a real amateur). This until I discovered Vue.js which changed my life. This and lodash made me actually like JS and front-end programming. So this is an example what a framework did not help to improve code but actually made me choose in something else than the language I…
Re: Ask HN: When has switching the language/framework made an important difference?
#69Re: Ask HN: When has switching the language/framework made an important difference?
#70Earlier quoted context omitted.
One can do it without restricting the range as well, if the full range of inputs is needed. In C: (n / 8) + !!(n % 8);
This is correct, and is sometimes necessary, but is a last-ditch save, since as written, it involves a branch. Much better if you can let the n+7 expand to a wider integer type. Or better yet, if you can ensure that it won't overflow in the first place -- which is what they did by restricting the type.