Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's Easy in F# That's Hard in C#? [duplicate]

Tags:

c#

f#

Possible Duplicate:
In what areas might the use of F# be more appropriate than C#?

I'm anticipating giving a presentation at the local .Net user group about F#. And I'm anticipating the "Why should I look into F#?" question from the audience. I know most of the stuff that can be done in F# can be done in C# too--so I'm looking for things that can be done easily in F# that are really hard to do in C# (e. g. pattern matching). And if there are already good answers to this question, please just link them in comments and I'll close this up. I did see a few things but if there's already a question that addresses this I didn't find it.

By the way, if any of the moderators want to mark this community wiki please feel free; this seems more like a survey question to me anyway.

like image 256
Onorio Catenacci Avatar asked Apr 28 '11 13:04

Onorio Catenacci


People also ask

What is the easy F chord?

The easy F chord starts with your index finger on the 1st fret of the 2nd string. Then use your middle finger on the 2nd fret of the 3rd string. Your ring finger and pinky will play the 3rd fret on the 5th and 4th strings respectively. For this version of the F chord, you won't play the high or low E strings.

What chord can I play instead of F?

We can play a simple triad shape across strings 4, 3 and 2. If I replace the A note on string 3 with the open G I create what is called an Fsus2. Adding an open string 1 to these shapes creates an Fmaj7 (commonly used by beginners to replace an F chord) or Fmaj7sus2.

How do you calculate F to C?

Fahrenheit to Celsius Exact Formula In other words, if you'd like to convert a temperature reading in Fahrenheit to Celsius: Start with the temperature in Fahrenheit (e.g., 100 degrees). Subtract 32 from this figure (e.g., 100 - 32 = 68). Divide your answer by 1.8 (e.g., 68 / 1.8 = 37.78)


3 Answers

Since F# is a functional language, it should be far easier to implement a domain-specific language in it.

like image 97
T.E.D. Avatar answered Nov 16 '22 02:11

T.E.D.


One of a main concept is asyncrounus calls in F#, also F# uses immutable variables so concurrency is easy.

see http://research.microsoft.com/apps/pubs/default.aspx?id=147194 and http://research.microsoft.com/apps/pubs/default.aspx?id=79947 and other Don Syme articles. may be there are other differences, but I think gathering them here is just doing your homework.

like image 34
Saeed Amiri Avatar answered Nov 16 '22 01:11

Saeed Amiri


i would say

  • Asynchronous programming.
  • Units of measure
like image 37
Maged Samaan Avatar answered Nov 16 '22 03:11

Maged Samaan