Re:F# for Fun and Profit
by pc86 on Thursday August 18, 2016 @08:13AM
(#12311855)
I hear it's particularly good for unit tests depending on the domain. I have a coworker who regularly writes his production code in C# and unit tests in F#. He says it's faster but I don't know enough F# to be able to say if that's true or if he just likes using both languages :)
[ Parent
| on HN ]
Re:F# for Fun and Profit
by kemiller2002 on Thursday August 18, 2016 @08:58AM
(#12312120)
Faster in what? They both compile to IL code, and there execution speed is relatively the same, C# has it beat on somethings F# wins in others. Development wise, once you get used to it, I find it much faster. I have to write less code, and it's generally more correct the first time due to the rules it enforces.
Re:F# for Fun and Profit
by markatkinson on Thursday August 18, 2016 @09:11AM
(#12312198)
I was about to mention perhaps they mean faster to write, and also conceptualise, but you nailed it.
I find with F# that sure you are writing less actual code, like 1000 characters instead of 2000, but for me the biggest gains from using/thinking in a functional paradigm, and having access to functional tools is in the process of actually tackling problems. The conceptualisation, execution and testing of solutions for these problems for me has been less onerous and more enjoyable with F# than using C#.