an introduction to fsharp
DESCRIPTION
This is the companion slides of a talk I gave for the .NET Miami user group on April 19th, 2012.TRANSCRIPT
![Page 2: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/2.jpg)
What is F#?
F# Interactive
F# 101 (less than 10 minutes!)
Walkthrough: Functional Numerical Matrixes
Online Resources
![Page 3: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/3.jpg)
F# is multi-paradigm programming language targeting
the .NET framework
![Page 4: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/4.jpg)
functional
object oriented
imperative
language oriented
F#
![Page 5: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/5.jpg)
Immutable values and data types
(No State => No Shared Memory)
let x = 10x = 10 //<!-- boolean
![Page 6: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/6.jpg)
High Order Functions
(functions can be parameters and results of other functions)
![Page 7: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/7.jpg)
Type Inference
Think in C#’s var… everywhere
![Page 8: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/8.jpg)
Declarative
Express the desired result, not the step-by-step recipe
![Page 9: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/9.jpg)
Lazy Evaluation
Use values only when you really need it
![Page 10: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/10.jpg)
Pattern Matching
The compiler “understands” types
![Page 11: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/11.jpg)
Imperative
![Page 12: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/12.jpg)
Mutable values and data types
(State => Probable Shared Memory)
let mutable x = 10x <- 10
![Page 13: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/13.jpg)
Object Oriented
![Page 14: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/14.jpg)
F# can consume and create OOP designs seamlessly
![Page 15: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/15.jpg)
also…
F# becomes MSIL, hard to read, but MSIL
![Page 16: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/16.jpg)
F# is fully supported in Visual Studio except for GUI Designers
![Page 17: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/17.jpg)
What is F#?
F# Interactive
F# 101 (less than 10 minutes!)
Walkthrough: Functional Numerical Matrixs
Online Resources
![Page 18: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/18.jpg)
What is F#?
F# Interactive
F# 101 (less than 10 minutes!)
Walkthrough: Functional Numerical Matrixs
Online Resources
![Page 19: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/19.jpg)
What is F#?
F# Interactive
F# 101 (less than 10 minutes!)
Walkthrough: Functional Numerical Matrixs
Online Resources
![Page 20: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/20.jpg)
Functional Abstractions for Numerical Matrixes
(𝑎 𝑏𝑐 𝑑)
![Page 21: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/21.jpg)
Have you ever tried to create a Matrix of order Int32.MaxValue?
![Page 22: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/22.jpg)
Out of Memory Exception!
![Page 23: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/23.jpg)
What is F#?
F# Interactive
F# 101 (less than 10 minutes!)
Walkthrough: Functional Numerical Matrixs
Online Resources
![Page 24: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/24.jpg)
ONLINE RESOURCES
Don Syme’ Blog (F# Designer)
http://blogs.msdn.com/b/dsyme/
Tomas Petricek's’ Blog
http://tomasp.net/
![Page 25: An Introduction to FSharp](https://reader035.vdocuments.net/reader035/viewer/2022062419/558cc0ebd8b42a7f788b4688/html5/thumbnails/25.jpg)
ONLINE RESOURCES
F# Snippets
http://fssnip.net/
Channel 9
http://channel9.msdn.com/
StackOverflow
http://stackoverflow.com/